Click here to Skip to main content
15,895,011 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Newbie C++ question Pin
Ian Darling5-Jan-04 11:43
Ian Darling5-Jan-04 11:43 
GeneralRe: Newbie C++ question Pin
Jörgen Sigvardsson5-Jan-04 12:53
Jörgen Sigvardsson5-Jan-04 12:53 
GeneralRe: Newbie C++ question Pin
David Crow6-Jan-04 5:16
David Crow6-Jan-04 5:16 
GeneralNewbie C++ question Pin
Anonymous5-Jan-04 11:25
Anonymous5-Jan-04 11:25 
QuestionHow to monitor file operations Pin
shaomin5-Jan-04 10:37
shaomin5-Jan-04 10:37 
AnswerRe: How to monitor file operations Pin
Ravi Bhavnani5-Jan-04 11:48
professionalRavi Bhavnani5-Jan-04 11:48 
GeneralRe: How to monitor file operations Pin
shaomin8-Jan-04 12:55
shaomin8-Jan-04 12:55 
GeneralCalling UpdateData(FALSE) will screw my RadioButton-group selection Pin
andreir235-Jan-04 9:33
andreir235-Jan-04 9:33 
Here's my problem:

I have 2 radio buttons in my dialog-based MFCAppWizard-made application (first radio button has "Group" property and is mapped to m_Operation). Their names are: "Encode" and "Decode"
By default (in OnInitDialog) I select the first radio button (otherwise none would be selected at startup) with:

m_Operation = 0;

I have 2 Static Text controls (IDC_SOURCE and IDC_DESTINATION) both mapped thru ClassWizard to m_Source (CString type) and m_Destination (CString also)

At a certain point the user selects a file and the app will write something to m_Source:

m_Source = "C:\\MyFile.txt";

But that won't make it visible in the main form so I:

UpdateData(FALSE);

And it becomes visible. But MY PROBLEM IS THAT IN THAT MOMENT THE RADIO BUTTON SELECTION SCREWS UP.
How is that? If "Decode" was selected before UpdateData(2nd radio button - "1") then "Encode" will become selected (1st radio button - "0").

HOW CAN I AVOID THIS? Not calling UpdateData or UpdateData() or UpdateData(TRUE) will cause this: m_Source = "C:\\AnyFile.txt"; does not update visually the static text control in my app.

Please help?! Wink | ;-)

Andrei Rinea
GeneralRe: Calling UpdateData(FALSE) will screw my RadioButton-group selection Pin
abc8765-Jan-04 10:05
abc8765-Jan-04 10:05 
GeneralRe: Calling UpdateData(FALSE) will screw my RadioButton-group selection Pin
David Crow5-Jan-04 10:13
David Crow5-Jan-04 10:13 
GeneralRe: Calling UpdateData(FALSE) will screw my RadioButton-group selection Pin
andreir235-Jan-04 11:17
andreir235-Jan-04 11:17 
GeneralRe: Calling UpdateData(FALSE) will screw my RadioButton-group selection Pin
abc8765-Jan-04 20:20
abc8765-Jan-04 20:20 
GeneralRe: Calling UpdateData(FALSE) will screw my RadioButton-group selection Pin
Nick Hodapp5-Jan-04 10:27
sitebuilderNick Hodapp5-Jan-04 10:27 
Generalsprintf formatting with conditional statement Pin
shultas5-Jan-04 8:45
shultas5-Jan-04 8:45 
GeneralRe: sprintf formatting with conditional statement Pin
Tyler Kellen5-Jan-04 8:49
Tyler Kellen5-Jan-04 8:49 
GeneralRe: sprintf formatting with conditional statement Pin
abc8765-Jan-04 8:57
abc8765-Jan-04 8:57 
GeneralRe: sprintf formatting with conditional statement Pin
Prakash Nadar5-Jan-04 16:08
Prakash Nadar5-Jan-04 16:08 
GeneralRe: sprintf formatting with conditional statement Pin
abc8765-Jan-04 19:47
abc8765-Jan-04 19:47 
GeneralRe: sprintf formatting with conditional statement Pin
Prakash Nadar5-Jan-04 20:15
Prakash Nadar5-Jan-04 20:15 
GeneralRe: sprintf formatting with conditional statement Pin
abc8765-Jan-04 20:34
abc8765-Jan-04 20:34 
GeneralRe: sprintf formatting with conditional statement Pin
Prakash Nadar5-Jan-04 21:28
Prakash Nadar5-Jan-04 21:28 
GeneralRe: sprintf formatting with conditional statement Pin
Ian Darling5-Jan-04 9:01
Ian Darling5-Jan-04 9:01 
GeneralRe: sprintf formatting with conditional statement Pin
Tyler Kellen5-Jan-04 9:05
Tyler Kellen5-Jan-04 9:05 
GeneralRe: sprintf formatting with conditional statement Pin
Jörgen Sigvardsson5-Jan-04 9:45
Jörgen Sigvardsson5-Jan-04 9:45 
GeneralRe: sprintf formatting with conditional statement Pin
Ian Darling5-Jan-04 9:53
Ian Darling5-Jan-04 9:53 

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.