Click here to Skip to main content
15,920,704 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Problem with SetWindowPos() function Pin
Nish Nishant9-Apr-03 18:23
sitebuilderNish Nishant9-Apr-03 18:23 
GeneralRe: Problem with SetWindowPos() function Pin
julia20009-Apr-03 19:20
julia20009-Apr-03 19:20 
GeneralModifyStyle(......) Pin
ZarrinPour9-Apr-03 17:32
ZarrinPour9-Apr-03 17:32 
GeneralRe: ModifyStyle(......) Pin
Dave Bryant9-Apr-03 17:55
Dave Bryant9-Apr-03 17:55 
GeneralRe: ModifyStyle(......) Pin
Maximilien10-Apr-03 2:36
Maximilien10-Apr-03 2:36 
GeneralWM_RBUTTONDOWN message in dialog-based application Pin
Member 2592879-Apr-03 16:21
Member 2592879-Apr-03 16:21 
GeneralRe: WM_RBUTTONDOWN message in dialog-based application Pin
Nish Nishant9-Apr-03 17:25
sitebuilderNish Nishant9-Apr-03 17:25 
GeneralI have a problem about ID_FILE_SAVE and ID_FILE_PRINT Pin
-=JoKeR=-9-Apr-03 15:40
-=JoKeR=-9-Apr-03 15:40 
My Scenario:
I’m using MFC on the VC7. I have a MDI application. I wrote a class that delivered from CToolBarCtrl. I created a few button. I added ID and icon on the buttons.

UINT cButtonID[] ={ ID_FILE_NEW
,ID_FILE_OPEN
,ID_FILE_SAVE
,ID_FILE_PRINT
,ID_APP_ABOUT
};
TBBUTTON TBButtons[ICON_NUMBER];
for(int i = 0; i < ICON_NUMBER; i++)
{
TBButtons[i].fsState = TBSTATE_ENABLED;
TBButtons[i].iBitmap = i;
TBButtons[i].idCommand = cButtonID[i];
TBButtons[i].iString = i;
TBButtons[i].fsStyle = TBSTYLE_BUTTON;
}
There is a dialog (CMyToolBar). When the dialog receives WM_CREATE message, I create an object from above class. On the CMainFrame When receive WM_CREATE message, I create two objects from CReBar and CMyToolBar. Object of CMyToolBar adds to Object of CReBar (m_ReBar.AddBar(&m_dlgToolBar)).
(I think, my way is very long. I guess, there is a shorter way, but I don’t know.)

My Problem:
When I click the new file button or open file button on the tool bar, it is run. But when I click the save file button or print button, it isn’t run. What is the problem?

( I know that my English is very bad. I'm Sorry!)
Everybody thanks for your helps.
GeneralRe: I have a problem about ID_FILE_SAVE and ID_FILE_PRINT Pin
CodeBrain9-Apr-03 21:38
CodeBrain9-Apr-03 21:38 
GeneralNT Driver Pin
John R. Shaw9-Apr-03 13:52
John R. Shaw9-Apr-03 13:52 
GeneralRe: NT Driver Pin
geo_m10-Apr-03 5:07
geo_m10-Apr-03 5:07 
GeneralRe: NT Driver Pin
John R. Shaw10-Apr-03 8:44
John R. Shaw10-Apr-03 8:44 
GeneralDAO and dialog based application Pin
midupk9-Apr-03 12:21
midupk9-Apr-03 12:21 
GeneralRe: DAO and dialog based application Pin
Joel Lucsy9-Apr-03 16:22
Joel Lucsy9-Apr-03 16:22 
Generalproblem with reading data from the disk drive. Pin
Anonymous9-Apr-03 11:35
Anonymous9-Apr-03 11:35 
GeneralRe: problem with reading data from the disk drive. Pin
Toni789-Apr-03 19:42
Toni789-Apr-03 19:42 
GeneralEasy one...but not for me :o) Pin
MemLeak9-Apr-03 9:57
MemLeak9-Apr-03 9:57 
GeneralRe: Easy one...but not for me :o) Pin
Ravi Bhavnani9-Apr-03 10:11
professionalRavi Bhavnani9-Apr-03 10:11 
GeneralRe: Easy one...but not for me :o) Pin
MemLeak9-Apr-03 10:12
MemLeak9-Apr-03 10:12 
GeneralMouseWheel and ScrollBar with CWnd Pin
leander9-Apr-03 9:16
leander9-Apr-03 9:16 
GeneralRe: MouseWheel and ScrollBar with CWnd Pin
leander9-Apr-03 21:36
leander9-Apr-03 21:36 
Questionuse UNICODE string ? Pin
_skidrow_vn_9-Apr-03 9:13
_skidrow_vn_9-Apr-03 9:13 
AnswerRe: use UNICODE string ? Pin
Tim Smith9-Apr-03 9:25
Tim Smith9-Apr-03 9:25 
GeneralRe: use UNICODE string ? Pin
_skidrow_vn_9-Apr-03 12:12
_skidrow_vn_9-Apr-03 12:12 
AnswerRe: use UNICODE string ? Pin
Dave Bryant9-Apr-03 9:30
Dave Bryant9-Apr-03 9:30 

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.