Click here to Skip to main content
15,898,134 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: How to get the available ports? Pin
David Crow13-Feb-09 3:03
David Crow13-Feb-09 3:03 
QuestionObtaining the HWND of a window Pin
hxhl9512-Feb-09 17:53
hxhl9512-Feb-09 17:53 
QuestionRe: Obtaining the HWND of a window Pin
«_Superman_»12-Feb-09 18:03
professional«_Superman_»12-Feb-09 18:03 
AnswerRe: Obtaining the HWND of a window Pin
hxhl9512-Feb-09 18:11
hxhl9512-Feb-09 18:11 
AnswerRe: Obtaining the HWND of a window Pin
SandipG 12-Feb-09 20:04
SandipG 12-Feb-09 20:04 
AnswerRe: Obtaining the HWND of a window Pin
Stuart Dootson12-Feb-09 21:59
professionalStuart Dootson12-Feb-09 21:59 
GeneralRe: Obtaining the HWND of a window Pin
hxhl9513-Feb-09 12:59
hxhl9513-Feb-09 12:59 
QuestionEM_REPLACESEL order of API's Pin
ForNow12-Feb-09 17:37
ForNow12-Feb-09 17:37 
Hi,

I was wondering what is the order of API calls to replace a peice of text in a Rich Edit Control Dialog

I do the following

WM_SETSEXT to send the Text the Rich Edit Dialog BOX

The EM_SETSEL 0,7 setting the selection for char 0 - 7

Then doing the SetCharFormat to set the Character fromat to red

memset( &cf, 0, sizeof cf );
cf.cbSize = sizeof cf;
cf.dwMask = CFM_COLOR;
cf.crTextColor = RGB(255,0,0);

SendMessage(RichWindow,EM_SETCHARFORMAT,SCF_SELECTION,(LPARAM) &cf);

Then the replacement text

strncpy(addr,"00000000",8);
SendMessage(RichWindow,EM_REPLACESEL,TRUE,(LPARAM) addr);

However more then 8 charcters are replaced seeems like 9 or 10
QuestionC++ Logging: Any recommendations? Pin
gvanto12-Feb-09 16:36
gvanto12-Feb-09 16:36 
QuestionRe: C++ Logging: Any recommendations? Pin
David Crow13-Feb-09 3:11
David Crow13-Feb-09 3:11 
AnswerRe: C++ Logging: Any recommendations? Pin
gvanto13-Feb-09 19:09
gvanto13-Feb-09 19:09 
QuestionAn struct declared within another struct. Pin
Comp_Users12-Feb-09 15:16
Comp_Users12-Feb-09 15:16 
AnswerRe: An struct declared within another struct. Pin
Rick York12-Feb-09 18:12
mveRick York12-Feb-09 18:12 
GeneralRe: An struct declared within another struct. Pin
Comp_Users12-Feb-09 18:26
Comp_Users12-Feb-09 18:26 
GeneralRe: An struct declared within another struct. Pin
Arman S.12-Feb-09 20:39
Arman S.12-Feb-09 20:39 
GeneralRe: An struct declared within another struct. Pin
Cedric Moonen12-Feb-09 20:48
Cedric Moonen12-Feb-09 20:48 
GeneralRe: An struct declared within another struct. Pin
Arman S.12-Feb-09 20:53
Arman S.12-Feb-09 20:53 
GeneralRe: An struct declared within another struct. Pin
Cedric Moonen12-Feb-09 21:03
Cedric Moonen12-Feb-09 21:03 
AnswerRe: An struct declared within another struct. Pin
Cedric Moonen12-Feb-09 20:35
Cedric Moonen12-Feb-09 20:35 
AnswerRe: An struct declared within another struct. Pin
Cedric Moonen12-Feb-09 20:45
Cedric Moonen12-Feb-09 20:45 
GeneralRe: An struct declared within another struct. [modified] Pin
Comp_Users12-Feb-09 21:13
Comp_Users12-Feb-09 21:13 
GeneralRe: An struct declared within another struct. Pin
Cedric Moonen12-Feb-09 21:21
Cedric Moonen12-Feb-09 21:21 
QuestionA Question about Buttons Pin
BobInNJ12-Feb-09 14:43
BobInNJ12-Feb-09 14:43 
AnswerRe: A Question about Buttons Pin
Arman S.12-Feb-09 22:38
Arman S.12-Feb-09 22:38 
GeneralRe: A Question about Buttons Pin
BobInNJ13-Feb-09 5:16
BobInNJ13-Feb-09 5:16 

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.