Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Save As Dialog

Just to add - at least in xl97 -
If the path is not valid, it does not raise an error. It goes somewhere
else.

--
Regards,
Tom Ogilvy


"Bob Phillips" wrote in message
...
Hi Nick,

That is interesting. It actually works better than that.

I tried C:\MyTest, and it went to C: as you said.

I then tried C:\Mytest\Mytest, and it went to c:\MyTest !

But best of all, I then tried C:\Mytest\Mytest\ and it went to
c:\MyTest\Mytest.

A good find.

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Nick Hodge" wrote in message
...
Larry

Can you not explicitly pass the path to the GetSaveAsFilename method. I

used
the code below and it offered the save as dialog with my root 'C' as the
'preset' path

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As
Boolean)
Dim sFileName As String
If SaveAsUI Then Exit Sub
With Application
.EnableEvents = False
sFileName = .GetSaveAsFilename("C:\" & Me.Name)
Me.SaveAs Filename:=sFileName
.EnableEvents = True
End With
End Sub


--
HTH
Nick Hodge
Microsoft MVP - Excel
Southampton, England
HIS


"Larry Dodd" wrote in message
...
Thank you for responding but that did not work for me. It does open

the
Save As dialog but it is in the folder that the original file was

opened
from. This is the code that I used. Please let me know if there is
something else that I need to do.

Also when I call the SaveAs function the file is saved to the location
that I selected but then Excel gives me an error message and closes.

If
you know anything about that please let me know

Application.EnableEvents = False
ChDir (ActiveWorkbook.Path)
ChDir ("Bone Match Template Directory")
ChDir ("Bone Match History")
strFile = Application.Dialogs(xlDialogSaveAs).Show
Application.EnableEvents = True



*** Sent via Developersdex
http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!







Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Save as dialog David T Excel Discussion (Misc queries) 7 September 28th 07 05:12 PM
how to get disk icon on save button of save as dialog like 2000 RichT Excel Discussion (Misc queries) 2 March 9th 06 08:13 PM
Changing Save As Type in Save as dialog box Phill Excel Programming 2 August 22nd 03 12:38 PM
Save As Dialog Arne[_2_] Excel Programming 0 July 9th 03 09:18 AM
Save As Dialog Bob Phillips[_5_] Excel Programming 0 July 8th 03 11:09 PM


All times are GMT +1. The time now is 04:34 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"