Click here to Skip to main content
15,899,679 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: MD5 using openssl Pin
shrims4u25-Jun-09 5:58
shrims4u25-Jun-09 5:58 
GeneralRe: MD5 using openssl Pin
Stuart Dootson25-Jun-09 6:06
professionalStuart Dootson25-Jun-09 6:06 
QuestionProblem Compiling in VS 2005 after installing microsoft platform SDK for Windows Server 2003 SP1 Pin
REDSERPENT724-Jun-09 22:11
REDSERPENT724-Jun-09 22:11 
AnswerRe: Problem Compiling in VS 2005 after installing microsoft platform SDK for Windows Server 2003 SP1 Pin
Naveen24-Jun-09 22:49
Naveen24-Jun-09 22:49 
GeneralRe: Problem Compiling in VS 2005 after installing microsoft platform SDK for Windows Server 2003 SP1 Pin
REDSERPENT724-Jun-09 22:58
REDSERPENT724-Jun-09 22:58 
GeneralRe: Problem Compiling in VS 2005 after installing microsoft platform SDK for Windows Server 2003 SP1 Pin
Naveen24-Jun-09 23:13
Naveen24-Jun-09 23:13 
GeneralRe: Problem Compiling in VS 2005 after installing microsoft platform SDK for Windows Server 2003 SP1 Pin
REDSERPENT724-Jun-09 23:25
REDSERPENT724-Jun-09 23:25 
GeneralRe: Problem Compiling in VS 2005 after installing microsoft platform SDK for Windows Server 2003 SP1 Pin
Naveen24-Jun-09 23:34
Naveen24-Jun-09 23:34 
AnswerRe: Problem Compiling in VS 2005 after installing microsoft platform SDK for Windows Server 2003 SP1 Pin
smitty015725-Jun-09 11:29
smitty015725-Jun-09 11:29 
Questionhow to convert bstr to char[256] Pin
ashish8patil24-Jun-09 22:04
ashish8patil24-Jun-09 22:04 
AnswerRe: how to convert bstr to char[256] Pin
Rajesh R Subramanian24-Jun-09 22:13
professionalRajesh R Subramanian24-Jun-09 22:13 
GeneralRe: how to convert bstr to char[256] Pin
ashish8patil24-Jun-09 22:27
ashish8patil24-Jun-09 22:27 
AnswerRe: how to convert bstr to char[256] Pin
CPallini24-Jun-09 22:19
mveCPallini24-Jun-09 22:19 
GeneralRe: how to convert bstr to char[256] Pin
ashish8patil24-Jun-09 22:20
ashish8patil24-Jun-09 22:20 
Questionwua api help Pin
ashish8patil24-Jun-09 20:28
ashish8patil24-Jun-09 20:28 
QuestionMTOM without .Net framework how ? Pin
ERLN24-Jun-09 19:58
ERLN24-Jun-09 19:58 
AnswerRe: MTOM without .Net framework how ? Pin
Stuart Dootson24-Jun-09 22:35
professionalStuart Dootson24-Jun-09 22:35 
Questionhmm... Now why did this work? Pin
UserNameless24-Jun-09 19:52
UserNameless24-Jun-09 19:52 
AnswerRe: hmm... Now why did this work? Pin
Rajesh R Subramanian24-Jun-09 20:19
professionalRajesh R Subramanian24-Jun-09 20:19 
GeneralRe: hmm... Now why did this work? Pin
UserNameless24-Jun-09 20:34
UserNameless24-Jun-09 20:34 
GeneralRe: hmm... Now why did this work? Pin
Rajesh R Subramanian24-Jun-09 21:01
professionalRajesh R Subramanian24-Jun-09 21:01 
You can even write inline assembly to manipulate everything. But the question is: Do you really need to do it, given that you're already using a framework which makes things much more simpler?

I am saying that you should not be using std::string in an MFC program. But given that CString does everything that you need to, I simply fail to see any justification for using std::string. (OK, you're manipulating files? Then you could use CFile or CStdioFile or ...).

And why do I use MFC when I can do everything with vanilla C or C++? Because I'd like to leave for home at 5.

I may use something like an std::string within an MFC program very rarely (may be I'm using some third party code and a function expects a reference to an std::string, or whatever)...


sadman89 wrote:
drive when I click the Open button. my code for it is:


You are again providing code in bits and pieces. That works for me and I can't tell you why it didn't work in your case unless I can see the whole of your code (relevant code, please).

See if this helps:
CFileDialog cfd(true);
CString szStr;
cfd.m_pOFN->lpstrInitialDir = _T("C:\\");
if(cfd.DoModal == IDOK)
{
  szStr = cfd.GetFileName();
  AfxMessageBox(szStr);
}



It is a crappy thing, but it's life -^ Carlo Pallini

GeneralRe: hmm... Now why did this work? Pin
UserNameless24-Jun-09 21:24
UserNameless24-Jun-09 21:24 
GeneralRe: hmm... Now why did this work? Pin
Rajesh R Subramanian24-Jun-09 22:03
professionalRajesh R Subramanian24-Jun-09 22:03 
GeneralRe: hmm... Now why did this work? Pin
UserNameless24-Jun-09 22:44
UserNameless24-Jun-09 22:44 
QuestionRe: hmm... Now why did this work? Pin
David Crow25-Jun-09 4:05
David Crow25-Jun-09 4: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.