Click here to Skip to main content
15,910,303 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Convert CString to Integer Pin
Renjith Ramachandran20-Dec-04 20:37
Renjith Ramachandran20-Dec-04 20:37 
GeneralProblems with appending, copying usigned char* data ----Pls help Pin
ledallam20-Dec-04 19:28
ledallam20-Dec-04 19:28 
GeneralRe: Problems with appending, copying usigned char* data ----Pls help Pin
Jon Hulatt20-Dec-04 22:05
Jon Hulatt20-Dec-04 22:05 
Generalwebservice Pin
hou_12620-Dec-04 19:03
hou_12620-Dec-04 19:03 
QuestionCreating an ActiveX? Pin
dSolariuM20-Dec-04 18:41
dSolariuM20-Dec-04 18:41 
GeneralAbout CEdit::LineLength Pin
freehawk20-Dec-04 18:28
freehawk20-Dec-04 18:28 
GeneralRe: About CEdit::LineLength Pin
David Crow21-Dec-04 2:07
David Crow21-Dec-04 2:07 
Generalownderdraw Pin
Tripura.K20-Dec-04 18:21
Tripura.K20-Dec-04 18:21 
hi everybody,
Can any one of u help me to brushing on a ownder draw button
I have few owner draw buttons on a dialogbox which is created in an SDI application and now i want to change the color of the buttons
can any one tell me what code do i need to write for that my code is as follow
void MybutCls::DrawItem(LPDRAWITEMSTRUCT lpDrawItemStruct)
{
::DrawFrameControl(lpDrawItemStruct->hDC, &lpDrawItemStruct->rcItem, DFC_BUTTON,DFCS_BUTTONPUSH|BS_DEFPUSHBUTTON);
//what should i add here
if(((0x8000 ==(0x8000 & GetKeyState(16))&& !caps)) || ((0x8000 ==(0x8000 & GetKeyState(16))&& caps)))
{
if(lpDrawItemStruct->CtlID==IDC_BUTTON49)
::DrawText(lpDrawItemStruct->hDC,"!",1,&lpDrawItemStruct->rcItem, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
if(lpDrawItemStruct->CtlID==IDC_BUTTON45)
::DrawText(lpDrawItemStruct->hDC,"_",1,&lpDrawItemStruct->rcItem, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
if(lpDrawItemStruct->CtlID==IDC_BUTTON39 )
::DrawText(lpDrawItemStruct->hDC,"\"",1,&lpDrawItemStruct->rcItem, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
if(lpDrawItemStruct->CtlID==IDC_BUTTON44)
::DrawText(lpDrawItemStruct->hDC,"<",1,&lpDrawItemStruct->rcItem, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
if(lpDrawItemStruct->CtlID==IDC_BUTTON46)
::DrawText(lpDrawItemStruct->hDC,">",1,&lpDrawItemStruct->rcItem, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
if(lpDrawItemStruct->CtlID==IDC_BUTTON47)
::DrawText(lpDrawItemStruct->hDC,"?",1,&lpDrawItemStruct->rcItem, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
if(lpDrawItemStruct->CtlID==IDC_BUTTON48)
::DrawText(lpDrawItemStruct->hDC,")",1,&lpDrawItemStruct->rcItem, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
if(lpDrawItemStruct->CtlID==IDC_BUTTON50)
::DrawText(lpDrawItemStruct->hDC,"@",1,&lpDrawItemStruct->rcItem, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
if(lpDrawItemStruct->CtlID==IDC_BUTTON51)
::DrawText(lpDrawItemStruct->hDC,"#",1,&lpDrawItemStruct->rcItem, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
if(lpDrawItemStruct->CtlID==IDC_BUTTON52)
::DrawText(lpDrawItemStruct->hDC,"$",1,&lpDrawItemStruct->rcItem, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
if(lpDrawItemStruct->CtlID==IDC_BUTTON53)
::DrawText(lpDrawItemStruct->hDC,"%",1,&lpDrawItemStruct->rcItem, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
if(lpDrawItemStruct->CtlID==IDC_BUTTON54)
::DrawText(lpDrawItemStruct->hDC,"^",1,&lpDrawItemStruct->rcItem, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
if(lpDrawItemStruct->CtlID==IDC_BUTTON55)
::DrawText(lpDrawItemStruct->hDC,"&",1,&lpDrawItemStruct->rcItem, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
if(lpDrawItemStruct->CtlID==IDC_BUTTON56)
::DrawText(lpDrawItemStruct->hDC,"*",1,&lpDrawItemStruct->rcItem, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
if(lpDrawItemStruct->CtlID==IDC_BUTTON57)
::DrawText(lpDrawItemStruct->hDC,"(",1,&lpDrawItemStruct->rcItem, DT_SINGLELINE|DT_VCENTER|DT_CENTER);
if(lpDrawItemStruct->CtlID==IDC_BUTTON59)
::DrawText(lpDrawItemStruct->hDC,":",1,&lpDrawItemStruct->rcItem, DT_SINGLELINE| DT_VCENTER|DT_CENTER);
}

Request to all to continue this
GeneralEncrypting Video File Data Pin
Naveed Shoaib20-Dec-04 18:19
Naveed Shoaib20-Dec-04 18:19 
GeneralRe: Encrypting Video File Data Pin
Antti Keskinen20-Dec-04 22:34
Antti Keskinen20-Dec-04 22:34 
Questionhow to associate MFC with lex and yacc? Pin
chenbuaa20-Dec-04 16:40
chenbuaa20-Dec-04 16:40 
AnswerRe: how to associate MFC with lex and yacc? Pin
David Crow21-Dec-04 2:18
David Crow21-Dec-04 2:18 
GeneralResource related crash Pin
JWood20-Dec-04 13:30
JWood20-Dec-04 13:30 
GeneralRe: Resource related crash Pin
Ryan Binns20-Dec-04 17:01
Ryan Binns20-Dec-04 17:01 
GeneralDrawDragRect Pin
poiut20-Dec-04 10:51
poiut20-Dec-04 10:51 
GeneralRe: DrawDragRect Pin
JWood20-Dec-04 13:37
JWood20-Dec-04 13:37 
GeneralRe: DrawDragRect Pin
poiut22-Dec-04 6:29
poiut22-Dec-04 6:29 
QuestionWhy is my printed image blown up? Pin
giannibal20-Dec-04 9:49
giannibal20-Dec-04 9:49 
GeneralHelp me with image displaying solutions Pin
Budric B.20-Dec-04 7:44
Budric B.20-Dec-04 7:44 
GeneralAlso... Pin
Budric B.20-Dec-04 7:49
Budric B.20-Dec-04 7:49 
GeneralRe: Also... Pin
Christian Graus20-Dec-04 9:45
protectorChristian Graus20-Dec-04 9:45 
GeneralRe: Help me with image displaying solutions Pin
Christian Graus20-Dec-04 9:43
protectorChristian Graus20-Dec-04 9:43 
GeneralRe: Help me with image displaying solutions Pin
Budric B.20-Dec-04 10:31
Budric B.20-Dec-04 10:31 
GeneralWindows Hook Pin
RedDragon2k20-Dec-04 5:13
RedDragon2k20-Dec-04 5:13 
GeneralRe: Windows Hook Pin
Michael Dunn20-Dec-04 7:17
sitebuilderMichael Dunn20-Dec-04 7:17 

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.