[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

[TSVN] Current working directory chagned when the "File Open" dialog box is used

From: Matthew Schnee <mschnee_at_fonix.com>
Date: 2005-06-10 16:57:21 CEST

Hi,

TortoiseSVN is changing the current working directory when the "file open"
dialog box is displayed.

The method to see this is to do the folllowing:
1. Open an application.
2. go to file open in the menu.
3. change directories and open a file in the other directory.
4. The current working directory has changed and relative path calls to
"fopen" no longer work.

This happens when the "File Open" dioalog box is displayed with one of the
following methods:

Method 1 in a .cpp file:
CFileDialog Filedlg(TRUE,".txt",NULL,OFN_OVERWRITEPROMPT, filter,NULL);

if(Filedlg.DoModal()==IDOK)
{

Method 2 in a .c file:

OpenFileName.lStructSize = sizeof(OPENFILENAME);
OpenFileName.hwndOwner = hWnd;
OpenFileName.hInstance = (HANDLE) hInst;
OpenFileName.lpstrFilter = szFilter;
OpenFileName.lpstrCustomFilter = (LPSTR) NULL;
OpenFileName.nMaxCustFilter = 0L;
OpenFileName.nFilterIndex = 1L;
OpenFileName.lpstrFile = szFile;
OpenFileName.nMaxFile = 256;
OpenFileName.lpstrFileTitle = szFileTitle;
OpenFileName.nMaxFileTitle = 256;
OpenFileName.lpstrInitialDir = NULL;
OpenFileName.lpstrTitle = "Open a File";
OpenFileName.nFileOffset = 0;
OpenFileName.nFileExtension = 0;
OpenFileName.lpstrDefExt = "txt";
OpenFileName.lCustData = 0;
OpenFileName.Flags = OFN_PATHMUSTEXIST | OFN_FILEMUSTEXIST |
OFN_HIDEREADONLY;

if ( GetOpenFileName(&OpenFileName))

Operating system: Windows xp and Windows 2000

I have a sample program that can show this problem if you like.

Please contact me off the mailing list as I am not subscribed.

Thanks,

Matthew Schnee

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tortoisesvn.tigris.org
For additional commands, e-mail: dev-help@tortoisesvn.tigris.org
Received on Fri Jun 10 16:57:03 2005

This is an archived mail posted to the TortoiseSVN Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.