Click here to Skip to main content
15,907,905 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: _beginthreadex() problem... Pin
jhoin19-Dec-03 5:06
jhoin19-Dec-03 5:06 
Generalneed urgent help! Pin
YaronNir17-Dec-03 3:37
YaronNir17-Dec-03 3:37 
GeneralRe: need urgent help! Pin
mightyCoCo17-Dec-03 3:58
mightyCoCo17-Dec-03 3:58 
GeneralRe: need urgent help! Pin
YaronNir17-Dec-03 4:00
YaronNir17-Dec-03 4:00 
GeneralRe: need urgent help! Pin
Don Kackman17-Dec-03 4:11
Don Kackman17-Dec-03 4:11 
GeneralRe: need urgent help! Pin
YaronNir17-Dec-03 4:23
YaronNir17-Dec-03 4:23 
GeneralRe: need urgent help! Pin
Don Kackman17-Dec-03 4:29
Don Kackman17-Dec-03 4:29 
GeneralRe: need urgent help! Pin
YaronNir17-Dec-03 4:44
YaronNir17-Dec-03 4:44 
my original problem was how to get the *.dsw file.

i saw a code that does that :

CString CCommands::GetWorkspacePath()
{
	CWinApp* pApp = AfxGetApp();
	ASSERT(NULL != pApp);
	
	CString szWorkspace(_T(""));

	POSITION posdt = pApp->GetFirstDocTemplatePosition();
	
	while (NULL != posdt)
	{
		CDocTemplate* pdt = pApp->GetNextDocTemplate(posdt);
		if (0 == strcmp("CProjectWorkspaceDocTemplate", 
			pdt->GetRuntimeClass()->m_lpszClassName))
		{
			POSITION posdoc = pdt->GetFirstDocPosition();
			if (NULL == posdoc) 
				break;

			CDocument* pdoc = pdt->GetNextDoc(posdoc);
			if (NULL == pdoc) 
				break;

			szWorkspace = pdoc->GetPathName();
			if (!szWorkspace.IsEmpty()) 
				break;
		}
	}

	return szWorkspace;
}


trouble was that when i run this code i got NULL for this line:

POSITION posdt = pApp->GetFirstDocTemplatePosition();


that's what led me to think that the pApp is the dlls therefor it can not get the doc template (cause it doesn't have one) what it should be is the dev studio exe and have a doc template.....


can you help me here? i am really desperate no one could help me here...

thanks again

Yaron


Ask not what your application can do for you,
Ask what you can do for your application
GeneralRe: need urgent help! Pin
Don Kackman17-Dec-03 5:04
Don Kackman17-Dec-03 5:04 
GeneralRe: need urgent help! Pin
YaronNir17-Dec-03 5:06
YaronNir17-Dec-03 5:06 
GeneralRe: need urgent help! Pin
Don Kackman17-Dec-03 5:11
Don Kackman17-Dec-03 5:11 
GeneralRe: need urgent help! Pin
YaronNir17-Dec-03 5:25
YaronNir17-Dec-03 5:25 
GeneralRe: need urgent help! Pin
Don Kackman17-Dec-03 5:36
Don Kackman17-Dec-03 5:36 
GeneralRe: need urgent help! Pin
YaronNir17-Dec-03 5:38
YaronNir17-Dec-03 5:38 
GeneralRe: need urgent help! Pin
Michael Dunn17-Dec-03 17:42
sitebuilderMichael Dunn17-Dec-03 17:42 
GeneralRe: need urgent help! Pin
YaronNir17-Dec-03 20:44
YaronNir17-Dec-03 20:44 
GeneralBrowser Helper Object : How to stop form being submitted Pin
Avya17-Dec-03 3:37
Avya17-Dec-03 3:37 
GeneralRe: Browser Helper Object : How to stop form being submitted Pin
Terry O'Nolley17-Dec-03 12:46
Terry O'Nolley17-Dec-03 12:46 
GeneralRe: Browser Helper Object : How to stop form being submitted Pin
Peter Molnar17-Dec-03 14:14
Peter Molnar17-Dec-03 14:14 
Generalinstant messanger like icq over proxy Pin
mightyCoCo17-Dec-03 2:37
mightyCoCo17-Dec-03 2:37 
GeneralRe: instant messanger like icq over proxy Pin
valikac17-Dec-03 4:59
valikac17-Dec-03 4:59 
GeneralRe: instant messanger like icq over proxy Pin
mightyCoCo17-Dec-03 5:12
mightyCoCo17-Dec-03 5:12 
GeneralRe: instant messanger like icq over proxy Pin
jmkhael17-Dec-03 7:42
jmkhael17-Dec-03 7:42 
GeneralRe: instant messanger like icq over proxy Pin
mightyCoCo17-Dec-03 8:02
mightyCoCo17-Dec-03 8:02 
Generalcursor did not change Pin
y_seval17-Dec-03 2:32
y_seval17-Dec-03 2:32 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.