Click here to Skip to main content
14,546,434 members

C / C++ / MFC

 
GeneralRe: Thanks for a new feature Pin
ZurdoDev1-Apr-20 3:59
mveZurdoDev1-Apr-20 3:59 
AnswerRe: Thanks for a new feature Pin
ZurdoDev1-Apr-20 3:59
mveZurdoDev1-Apr-20 3:59 
QuestionGetting 2203 error while doing silent installation of MSI Pin
Vijay53330-Mar-20 3:34
MemberVijay53330-Mar-20 3:34 
AnswerRe: Getting 2203 error while doing silent installation of MSI Pin
Richard MacCutchan30-Mar-20 3:36
mveRichard MacCutchan30-Mar-20 3:36 
AnswerRe: Getting 2203 error while doing silent installation of MSI Pin
Dave Kreskowiak30-Mar-20 3:51
mveDave Kreskowiak30-Mar-20 3:51 
GeneralRe: Getting 2203 error while doing silent installation of MSI Pin
Vijay53331-Mar-20 0:33
MemberVijay53331-Mar-20 0:33 
GeneralRe: Getting 2203 error while doing silent installation of MSI Pin
Dave Kreskowiak31-Mar-20 4:55
mveDave Kreskowiak31-Mar-20 4:55 
QuestionFinding a directory Pin
Anthony Appleyard29-Mar-20 18:32
MemberAnthony Appleyard29-Mar-20 18:32 
Thanks for your help to people who ask queries.

I know how to ask for a file to read from, or a file to write to :-

BOOL GetFileName(HWND wn,char*file,char*titl,char*filter,short write/*=1*/) {short j;
strcpy(file,title);
ofn.lStructSize=sizeof(OPENFILENAME); ofn.hwndOwner=wn;
ofn.lpstrFilter=filter; ofn.lpstrCustomFilter=0;
ofn.lpstrFile=file; ofn.nMaxFile=1024;
ofn.lpstrFileTitle=title; ofn.nMaxFileTitle=1024;
ofn.lpstrInitialDir=0; ofn.lpstrTitle=titl;
ofn.Flags=write?OFN_OVERWRITEPROMPT:OFN_FILEMUSTEXIST;
j=(write?GetSaveFileName(&ofn):GetOpenFileName(&ofn))?1:0;
return j;}


('ofn' and 'title' are declared globally.)

but when I need to ask for a directory / folder, I must do something like this:

K=GetFileName(wn, slidefilename, "name of a file in the directory to read slides from?", slidefiletype, 0);


Is there something like GetOpenFileName, but returning the name of a directory rather than the name of a file?

modified 30-Mar-20 0:49am.

AnswerRe: Finding a directory Pin
leon de boer29-Mar-20 20:26
Memberleon de boer29-Mar-20 20:26 
QuestionPassing an array as argument to a function Pin
fearless_28-Mar-20 22:15
Memberfearless_28-Mar-20 22:15 
AnswerRe: Passing an array as argument to a function Pin
Richard MacCutchan28-Mar-20 22:34
mveRichard MacCutchan28-Mar-20 22:34 
GeneralRe: Passing an array as argument to a function Pin
fearless_28-Mar-20 22:59
Memberfearless_28-Mar-20 22:59 
GeneralRe: Passing an array as argument to a function Pin
Richard MacCutchan28-Mar-20 23:23
mveRichard MacCutchan28-Mar-20 23:23 
GeneralRe: Passing an array as argument to a function Pin
fearless_28-Mar-20 23:44
Memberfearless_28-Mar-20 23:44 
GeneralRe: Passing an array as argument to a function Pin
Richard MacCutchan28-Mar-20 23:55
mveRichard MacCutchan28-Mar-20 23:55 
GeneralRe: Passing an array as argument to a function Pin
fearless_29-Mar-20 0:48
Memberfearless_29-Mar-20 0:48 
GeneralRe: Passing an array as argument to a function Pin
Richard MacCutchan29-Mar-20 0:50
mveRichard MacCutchan29-Mar-20 0:50 
GeneralRe: Passing an array as argument to a function Pin
fearless_29-Mar-20 1:14
Memberfearless_29-Mar-20 1:14 
GeneralRe: Passing an array as argument to a function Pin
k505429-Mar-20 4:03
mvek505429-Mar-20 4:03 
GeneralRe: Passing an array as argument to a function Pin
Richard MacCutchan29-Mar-20 4:18
mveRichard MacCutchan29-Mar-20 4:18 
GeneralRe: Passing an array as argument to a function Pin
leon de boer29-Mar-20 4:23
Memberleon de boer29-Mar-20 4:23 
GeneralRe: Passing an array as argument to a function Pin
Richard MacCutchan29-Mar-20 4:28
mveRichard MacCutchan29-Mar-20 4:28 
GeneralRe: Passing an array as argument to a function Pin
k505429-Mar-20 4:34
mvek505429-Mar-20 4:34 
GeneralRe: Passing an array as argument to a function Pin
Richard MacCutchan29-Mar-20 5:48
mveRichard MacCutchan29-Mar-20 5:48 
GeneralRe: Passing an array as argument to a function Pin
Stefan_Lang30-Mar-20 23:05
mveStefan_Lang30-Mar-20 23:05 

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.