Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 8
Default How to change the default directory

Hello,

I tried to change the default directory by the following setting:

ChDir "D:\My documents\toto\"

The I open a dilog box to select a file in this default directory with the
following procedu

Dim oDialog As Office.FileDialog
Set oDialog = XLApp.FileDialog(msoFileDialogFilePicker)
oDialog.Filters.Add "Fichiers Excel", "*.xls"
oDialog.Title = "Sélectionnez le fichier Excel"
oDialog.AllowMultiSelect = False
oDialog.Show

But this dialog remains opened on "My documents" and not on "D:\My
documents\toto\"
What am I missing ?
Thanks for your help

Woody


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10,593
Default How to change the default directory

ChDrive "D:\My documents\toto\"
ChDir "D:\My documents\toto\"


--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"Woody" wrote in message
...
Hello,

I tried to change the default directory by the following setting:

ChDir "D:\My documents\toto\"

The I open a dilog box to select a file in this default directory with the
following procedu

Dim oDialog As Office.FileDialog
Set oDialog = XLApp.FileDialog(msoFileDialogFilePicker)
oDialog.Filters.Add "Fichiers Excel", "*.xls"
oDialog.Title = "Sélectionnez le fichier Excel"
oDialog.AllowMultiSelect = False
oDialog.Show

But this dialog remains opened on "My documents" and not on "D:\My
documents\toto\"
What am I missing ?
Thanks for your help

Woody




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 File Open default directory from My Documents Ben Setting up and Configuration of Excel 3 January 1st 21 12:42 PM
change directory to list default edbrog Excel Discussion (Misc queries) 2 January 31st 09 06:19 PM
Change current directory to the directory that the workbook loads from! alondon Excel Programming 5 April 17th 07 06:05 AM
Force use of the Default Directory CLR Excel Programming 3 February 6th 07 09:20 PM
Set Default Directory bw Excel Programming 4 July 30th 03 11:45 PM


All times are GMT +1. The time now is 10:06 PM.

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"