Hi guys,
Probably a n00b question. But how do I convince the Common Dialog to accept me selecting nothinh in a given filepath so that I can only collect the path.
I need this for setting project folder roots and so on.
I need to use a different call perhaps than GetOpenFileName.
Thanks guys in advance.
cheers.
Kebab
Probably a n00b question. But how do I convince the Common Dialog to accept me selecting nothinh in a given filepath so that I can only collect the path.
I need this for setting project folder roots and so on.
Code:
OPENFILENAME ofn; char buf[256]; buf[0] = NULL;
memset(&ofn,0,sizeof(ofn));
ofn.lStructSize = sizeof(ofn);
ofn.hwndOwner = Wnd;
ofn.lpstrFile = buf;
ofn.nMaxFile = sizeof(buf);
ofn.lpstrFilter = "Project Files (*.prj)\0*.prj\0All Files(*.*)\0*.*\0";
ofn.Flags = OFN_HIDEREADONLY;
if(!GetOpenFileName(&ofn)) return;
I need to use a different call perhaps than GetOpenFileName.
Thanks guys in advance.
cheers.
Kebab