Click here to Skip to main content
15,922,145 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
General(mfc) Checking a checkbox during CPropertyPage constructor Pin
Simon Walton26-Oct-01 6:27
Simon Walton26-Oct-01 6:27 
GeneralRe: (mfc) Checking a checkbox during CPropertyPage constructor Pin
Chris Losinger26-Oct-01 6:42
professionalChris Losinger26-Oct-01 6:42 
GeneralRe: (mfc) Checking a checkbox during CPropertyPage constructor Pin
Simon Walton26-Oct-01 7:13
Simon Walton26-Oct-01 7:13 
GeneralRe: (mfc) Checking a checkbox during CPropertyPage constructor Pin
Carlos Antollini26-Oct-01 6:52
Carlos Antollini26-Oct-01 6:52 
GeneralRe: (mfc) Checking a checkbox during CPropertyPage constructor Pin
Carlos Antollini26-Oct-01 6:54
Carlos Antollini26-Oct-01 6:54 
GeneralRe: (mfc) Checking a checkbox during CPropertyPage constructor Pin
Carlos Antollini26-Oct-01 6:56
Carlos Antollini26-Oct-01 6:56 
GeneralCMainFrame::PreCreateWindow(CREATESTRUCT& cs) Pin
vhalik26-Oct-01 6:06
vhalik26-Oct-01 6:06 
GeneralRe: CMainFrame::PreCreateWindow(CREATESTRUCT& cs) Pin
Fazlul Kabir26-Oct-01 6:36
Fazlul Kabir26-Oct-01 6:36 
GeneralRe: CMainFrame::PreCreateWindow(CREATESTRUCT& cs) Pin
vhalik26-Oct-01 6:39
vhalik26-Oct-01 6:39 
GeneralRe: CMainFrame::PreCreateWindow(CREATESTRUCT& cs) Pin
vhalik26-Oct-01 6:57
vhalik26-Oct-01 6:57 
GeneralRe: CMainFrame::PreCreateWindow(CREATESTRUCT& cs) Pin
Fazlul Kabir26-Oct-01 7:03
Fazlul Kabir26-Oct-01 7:03 
GeneralRe: CMainFrame::PreCreateWindow(CREATESTRUCT& cs) Pin
Fazlul Kabir26-Oct-01 7:40
Fazlul Kabir26-Oct-01 7:40 
GeneralRe: CMainFrame::PreCreateWindow(CREATESTRUCT& cs) Pin
vhalik26-Oct-01 7:50
vhalik26-Oct-01 7:50 
GeneralCritical Section problems... Pin
LukeV26-Oct-01 5:59
LukeV26-Oct-01 5:59 
GeneralRe: Critical Section problems... Pin
Joaquín M López Muñoz26-Oct-01 7:16
Joaquín M López Muñoz26-Oct-01 7:16 
GeneralRe: Critical Section problems... Pin
LukeV26-Oct-01 7:49
LukeV26-Oct-01 7:49 
GeneralRe: Critical Section problems... Pin
Joaquín M López Muñoz26-Oct-01 8:30
Joaquín M López Muñoz26-Oct-01 8:30 
GeneralRe: Critical Section problems... Pin
Tim Deveaux26-Oct-01 10:20
Tim Deveaux26-Oct-01 10:20 
GeneralRe: Critical Section problems... Pin
HintiFlo23-Jan-02 1:12
HintiFlo23-Jan-02 1:12 
QuestionHow to set a bitmap as a dialog background ? Pin
adara26-Oct-01 4:58
adara26-Oct-01 4:58 
AnswerRe: How to set a bitmap as a dialog background ? Pin
Joaquín M López Muñoz26-Oct-01 5:48
Joaquín M López Muñoz26-Oct-01 5:48 
Generalthanx Pin
adara26-Oct-01 12:19
adara26-Oct-01 12:19 
Generaloverload resolution in VC 6.0 Pin
Patrick D Owens26-Oct-01 4:46
Patrick D Owens26-Oct-01 4:46 
GeneralRe: overload resolution in VC 6.0 Pin
Chris Losinger26-Oct-01 4:55
professionalChris Losinger26-Oct-01 4:55 
GeneralRe: overload resolution in VC 6.0 Pin
Patrick D Owens26-Oct-01 5:16
Patrick D Owens26-Oct-01 5:16 
I tried
strTemp2 = strTemp1 + (long)lTemp1;
and it still gives the C2666 error.
I agree that it probably can't decide the type of that second value, but I have tried changing the overload definitions to

PCSGENRL_EXP_TYPE friend PString operator +(const PString& string, const long& value);
and
PCSGENRL_EXP_TYPE friend PString operator +(const PString& string, long& value);
and
PCSGENRL_EXP_TYPE friend PString operator +(const PString& string, long value);

From what I have read on this error in the help pages, if the compiler can't find an exact match, then it will try to do some conversions to get a match.
You would think that one of the above 3 overloaded definitions would give an exact match so the compiler wouldn't have to do any conversions. But I guess I am missing something. I assume the first argument is fine because I can add a PString and a PString. So it must be something with the second (long) argument, but I can't figure it out.


Pat

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.