Gurus,
Any code lying around the place that allows a "Browse" option for choosing the path you save a file to
Gurus,
Any code lying around the place that allows a "Browse" option for choosing the path you save a file to
Kindest Regards,
Mike
I love to Excel
Look at GetSaveAsFilename in VBA Help.
____________________________________________
Nihil simul inventum est et perfectum
Abusus non tollit usum
Last night I dreamed of a small consolation enjoyed only by the blind: Nobody knows the trouble I've not seen!
James Thurber
I'm trying to remember if GetSaveAsFilename always worked... was it in existence in Office 97? Probably not an issue anymore anyway, but here is an alternative.
Ken Puls, CMA - Microsoft MVP (Excel)
I hate it when my computer does what I tell it to, and not what I want it to.
Learn how to use our KB tags! -||- Ken's Excel Website -||- Ken's Excel Forums -||- My Blog -||- Excel Training Calendar
This is a shameless plug for my new book "RibbonX - Customizing the Office 2007 Ribbon". Find out more about it here!
Help keep VBAX clean! Use the 'Thread Tools' menu to mark your own threads solved!
Following on Bob's suggestion. Change the Z:\Temp part to reflect the directory where you wish to start browsing:
[vba]Option Explicit
Sub a()
Dim FName As Variant
FName = Application.GetSaveAsFilename(InitialFileName:="Z:\Temp")
If FName = False Then
'Cancel
Else
ActiveWorkbook.SaveAs Filename:=FName, FileFormat:=xlNormal
End If
End Sub[/vba]
Steve
"Nearly all men can stand adversity, but if you want to test a man's character, give him power."
-Abraham Lincoln
Thank You Gurus
Kindest Regards,
Mike
I love to Excel