Click here to Skip to main content
15,917,061 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Property Sheet ; IShellPropSheetExt, IShellExtInit ? Pin
Erik Thompson16-May-00 6:48
sitebuilderErik Thompson16-May-00 6:48 
GeneralHelp!! How to change the ListBox and EditBox background & text color without using MFC!! Thanks.. Pin
Jason Hsu10-May-00 1:25
Jason Hsu10-May-00 1:25 
GeneralRe: Help!! How to change the ListBox and EditBox background & text color without using MFC!! Thanks.. Pin
Kurt10-May-00 1:35
Kurt10-May-00 1:35 
GeneralBand Pin
Member 23759-May-00 16:07
Member 23759-May-00 16:07 
GeneralRe: Band Pin
Alex Gorev10-May-00 4:19
Alex Gorev10-May-00 4:19 
QuestionLPCOLESTR? Pin
Alain Royer9-May-00 10:33
Alain Royer9-May-00 10:33 
AnswerRe: LPCOLESTR? Pin
Alex Gorev9-May-00 11:01
Alex Gorev9-May-00 11:01 
AnswerRe: LPCOLESTR? Pin
Dundas TCP/IP Support9-May-00 11:29
Dundas TCP/IP Support9-May-00 11:29 
Hi,
Use AnsiToUnicode( )
&
UnicodeToAnsi()


here are two examples
OPENFILENAME ofn;
LPOLESTR pszFileNameW;
LPMONIKER pmk;
..
......
// Get file name from OpenFile Common Dialog. The ANSI file name will
// be placed in ofn.lpstrFile
GetOpenFileName(&ofn);
..
......
AnsiToUnicode(ofn.lpstrFile, &pszFileNameW);
CreateFileMoniker(pszFileNameW, &pmk);
CoTaskMemFree(pszFileNameW);
..
......
COleInPlaceFrame::SetStatusText(LPCOLESTR pszStatusTextW)
{

LPSTR pszStatusTextA;
UnicodeToAnsi(pszStatusTextW, &pszStatusTextA);
SetWindowText(m_hwndStatus, pszStatusTextA);
CoTaskMemFree(pszStatusTextA);
}

See Also OLE2CT()

Hope That will help
Ghazi

GeneralMetafile output on Win98 problem Pin
Chris Losinger9-May-00 9:27
professionalChris Losinger9-May-00 9:27 
GeneralRe: Metafile output on Win98 problem Pin
Gert Boddaert10-May-00 3:17
Gert Boddaert10-May-00 3:17 
QuestionHow to call a com object's method that takes VARIANT * parameters? Pin
plu9-May-00 6:55
plu9-May-00 6:55 
AnswerRe: How to call a com object's method that takes VARIANT * parameters? Pin
Member 10549-May-00 8:29
Member 10549-May-00 8:29 
QuestionHow to call other class functions from another class Pin
olive9-May-00 4:14
olive9-May-00 4:14 
GeneralDisplaying the Property Sheet for a file Pin
magesh9-May-00 2:42
magesh9-May-00 2:42 
GeneralRe: Displaying the Property Sheet for a file Pin
Mike Dunn9-May-00 15:51
Mike Dunn9-May-00 15:51 
GeneralRe: Displaying the Property Sheet for a file Pin
magesh9-May-00 19:24
magesh9-May-00 19:24 
GeneralRe: Displaying the Property Sheet for a file Pin
magesh9-May-00 19:25
magesh9-May-00 19:25 
GeneralRe: Displaying the Property Sheet for a file Pin
Brian Hart25-Jun-00 13:37
Brian Hart25-Jun-00 13:37 
GeneralRemoving caption bar in toolbar Pin
Andrebon9-May-00 2:20
Andrebon9-May-00 2:20 
GeneralRe: Removing caption bar in toolbar Pin
Cristi Posea9-May-00 4:38
Cristi Posea9-May-00 4:38 
GeneralControls Pin
Ravi8-May-00 23:25
Ravi8-May-00 23:25 
GeneralRe: Controls Pin
Mike Dunn9-May-00 15:58
Mike Dunn9-May-00 15:58 
QuestionHow to use ActiveX without dialog ? Pin
Member 36018-May-00 15:02
Member 36018-May-00 15:02 
AnswerRe: How to use ActiveX without dialog ? Pin
Hussam Ahmad8-May-00 21:30
Hussam Ahmad8-May-00 21:30 
GeneralRe: How to use ActiveX without dialog ? Pin
Kurt10-May-00 1:48
Kurt10-May-00 1:48 

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.