Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 504
Default Default File Location

I save the default value and restore it. My problem is, this is not working
consistently. Sometimes I can set the value and sometimes I can not.

Kevin

"keepITcool" wrote:

I'd NOT interfere with the DefaultFilePath.
(some users are attached to it..)

I'd define a constant somewhere
Public const sPATH = "C:\Mydir"

and code like..

ChDrive sPATH
ChDir sPATH



keepITcool

< email : keepitcool chello nl (with @ and .)
< homepage: http://members.chello.nl/keepitcool


?B?S2V2aW4=?= wrote in message
:

I am attempting to set the Default File Location for an application I
m developing. I am using the following comand:

Application.DefaultFilePath = "C:\myPath"

I save the existing value and want to reset when the file exits. My
problem is, this works intermittently and I am not sure why. I can
grab and save the existing value with no problem, but setting this
value does not always work. Any ideas? The path exists, so it is not
that the correct path does not exist.

Thanks in advance for the help!

Kevin



  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,253
Default Default File Location

Forget the defaultfilepath.

Excel uses it ONLY when it starts... to set the current directory.
(the directory remains current until the user decides to select another
one.


As I said.. the only way to be sure of 'being' in a folder is to change
to it before you show any dialogs or open/save files.




--
keepITcool
| www.XLsupport.com | keepITcool chello nl | amsterdam


Kevin wrote :

I save the default value and restore it. My problem is, this is not
working consistently. Sometimes I can set the value and sometimes I
can not.

Kevin

"keepITcool" wrote:

I'd NOT interfere with the DefaultFilePath.
(some users are attached to it..)

I'd define a constant somewhere
Public const sPATH = "C:\Mydir"

and code like..

ChDrive sPATH
ChDir sPATH



keepITcool

< email : keepitcool chello nl (with @ and .)
< homepage: http://members.chello.nl/keepitcool


?B?S2V2aW4=?= wrote in message
:

I am attempting to set the Default File Location for an
application I m developing. I am using the following comand:

Application.DefaultFilePath = "C:\myPath"

I save the existing value and want to reset when the file exits.
My problem is, this works intermittently and I am not sure why. I
can grab and save the existing value with no problem, but setting
this value does not always work. Any ideas? The path exists, so
it is not that the correct path does not exist.

Thanks in advance for the help!

Kevin



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
How do I change the default log file location? Revs Setting up and Configuration of Excel 0 November 18th 08 01:24 PM
Default file location Marvin Excel Discussion (Misc queries) 1 April 16th 08 08:46 PM
Default file location hmburg52 Setting up and Configuration of Excel 2 January 25th 07 10:02 AM
Locked out of default file location Paul Donaldson Excel Discussion (Misc queries) 2 May 25th 05 10:01 PM
default file location maryj Excel Discussion (Misc queries) 2 March 3rd 05 06:09 PM


All times are GMT +1. The time now is 02:22 AM.

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

About Us

"It's about Microsoft Excel"