Click here to Skip to main content
15,896,727 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
Generale trefreshes the BitMap image Pin
a_david12313-Jun-05 23:17
a_david12313-Jun-05 23:17 
GeneralRe: e trefreshes the BitMap image Pin
Christian Graus14-Jun-05 1:24
protectorChristian Graus14-Jun-05 1:24 
GeneralRe: e trefreshes the BitMap image Pin
a_david12315-Jun-05 20:27
a_david12315-Jun-05 20:27 
GeneralRe: e trefreshes the BitMap image Pin
Christian Graus16-Jun-05 12:08
protectorChristian Graus16-Jun-05 12:08 
General"AfterEdit" event not getting called Pin
Pazzuzu13-Jun-05 23:00
Pazzuzu13-Jun-05 23:00 
GeneralSpawning Pin
Kash13-Jun-05 22:19
Kash13-Jun-05 22:19 
GeneralRe: Spawning Pin
David Crow14-Jun-05 3:18
David Crow14-Jun-05 3:18 
GeneralDynamically Change Menu Text Pin
sweep12313-Jun-05 21:52
sweep12313-Jun-05 21:52 
I would like to toggle sound in my program via a Menu item.

I have included a Menu option and event as follows, but how can I either set the Menu text 'checked' or change it to read:

Sound On or Sound Off.

void CExampleDlg::OnSystemSound()
{
	/* Toggle the sound On/Off. The default state is On.	*/
	if(g_bSound)
	{
		g_bSound = false;
		SetDlgItemText(ID_SYSTEM_SOUND, "Sound Off");
	}
	else
	{
		g_bSound = true;
		SetDlgItemText(ID_SYSTEM_SOUND, "Sound On");
	}
}


Where ID_SYSTEM_SOUND is the Menu item. Can you declare a member variable for this Menu item? I saw no options in the Class Wizard.

But the Menu always displays the default text (Sound On); i.e. never changes.
GeneralRe: Dynamically Change Menu Text Pin
Weiye Chen13-Jun-05 22:44
Weiye Chen13-Jun-05 22:44 
GeneralRe: Dynamically Change Menu Text Pin
Nilesh K.13-Jun-05 23:01
Nilesh K.13-Jun-05 23:01 
GeneralRe: Dynamically Change Menu Text Pin
sweep12313-Jun-05 20:24
sweep12313-Jun-05 20:24 
Generali want ask about this code Pin
kosamoza13-Jun-05 20:47
kosamoza13-Jun-05 20:47 
GeneralRe: i want ask about this code Pin
Nilesh K.13-Jun-05 21:21
Nilesh K.13-Jun-05 21:21 
GeneralRe: i want ask about this code Pin
kosamoza13-Jun-05 22:14
kosamoza13-Jun-05 22:14 
GeneralRe: i want ask about this code Pin
Weiye Chen13-Jun-05 22:54
Weiye Chen13-Jun-05 22:54 
GeneralRe: i want ask about this code Pin
Stlan13-Jun-05 22:57
Stlan13-Jun-05 22:57 
QuestionAny material available to make simulator for 8085 microprocessor in C, C++ ? Pin
Amarelia13-Jun-05 20:44
Amarelia13-Jun-05 20:44 
AnswerRe: Any material available to make simulator for 8085 microprocessor in C, C++ ? Pin
Nilesh K.13-Jun-05 21:24
Nilesh K.13-Jun-05 21:24 
AnswerRe: Any material available to make simulator for 8085 microprocessor in C, C++ ? Pin
Rick York14-Jun-05 10:20
mveRick York14-Jun-05 10:20 
GeneralMSXML2::IXMLDOMDocument::save a xml doc Pin
Saurabh_Delhi13-Jun-05 17:22
Saurabh_Delhi13-Jun-05 17:22 
GeneralRe: MSXML2::IXMLDOMDocument::save a xml doc Pin
ThatsAlok13-Jun-05 23:32
ThatsAlok13-Jun-05 23:32 
GeneralRe: MSXML2::IXMLDOMDocument::save a xml doc Pin
Saurabh_Delhi14-Jun-05 3:47
Saurabh_Delhi14-Jun-05 3:47 
GeneralRe: MSXML2::IXMLDOMDocument::save a xml doc Pin
ThatsAlok14-Jun-05 18:26
ThatsAlok14-Jun-05 18:26 
GeneralDropdown toolbuttons Pin
laiju13-Jun-05 20:05
laiju13-Jun-05 20:05 
GeneralRe: Dropdown toolbuttons Pin
Iain Clarke, Warrior Programmer14-Jun-05 0:13
Iain Clarke, Warrior Programmer14-Jun-05 0:13 

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.