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

C / C++ / MFC

 
GeneralRe: Reference are always lvalue? Pin
George_George21-Dec-07 19:16
George_George21-Dec-07 19:16 
Questionhow to get the number of lines shown in editbox Pin
rajneshmalik21-Dec-07 1:06
rajneshmalik21-Dec-07 1:06 
AnswerRe: how to get the number of lines shown in editbox Pin
CPallini21-Dec-07 3:05
mveCPallini21-Dec-07 3:05 
GeneralDatashowing problem want to get rid of from if-else statement Pin
Y_Kaushik20-Dec-07 23:53
Y_Kaushik20-Dec-07 23:53 
GeneralRe: Datashowing problem want to get rid of from if-else statement Pin
Hamid_RT21-Dec-07 0:02
Hamid_RT21-Dec-07 0:02 
GeneralRe: Datashowing problem want to get rid of from if-else statement Pin
Cedric Moonen21-Dec-07 0:13
Cedric Moonen21-Dec-07 0:13 
GeneralRe: Datashowing problem want to get rid of from if-else statement Pin
Cedric Moonen21-Dec-07 0:11
Cedric Moonen21-Dec-07 0:11 
GeneralRe: Datashowing problem want to get rid of from if-else statement Pin
Matthew Faithfull21-Dec-07 0:11
Matthew Faithfull21-Dec-07 0:11 
Two things you could do here.

Use a switch statement

<br />
switch i<br />
{<br />
  case 1:<br />
   //Do stuff<br />
   break;<br />
  case 2:<br />
    //Do other stuff<br />
   break;<br />
}<br />


but I wouldn't recommend that if you really have 200 fields and 200 controls on your dialog. If that's the case the easiest way is to ensure the values of your control id's are sequential and then do something like this

<br />
for(i=0;i<no_field;i++)<br />
{<br />
  rs.GetFieldValue(i,sString);<br />
  SetDlgItemText( BASE_FIELD_CONTROL_ID + i, sString);<br />
  sString.Empty();<br />
  rs.MoveNext();<br />
}<br />


you might want to use different ranges based on field/control types and use a switch to change the SetDlgItemText call.
Nothing is exactly what it seems but everything with seems can be unpicked.

GeneralRe: Datashowing problem want to get rid of from if-else statement Pin
Y_Kaushik21-Dec-07 19:08
Y_Kaushik21-Dec-07 19:08 
GeneralDynamically providing version information to a exe Pin
neha.agarwal2720-Dec-07 22:50
neha.agarwal2720-Dec-07 22:50 
GeneralRe: Dynamically providing version information to a exe Pin
jhwurmbach20-Dec-07 23:08
jhwurmbach20-Dec-07 23:08 
GeneralRe: Dynamically providing version information to a exe Pin
Chris Losinger21-Dec-07 5:45
professionalChris Losinger21-Dec-07 5:45 
GeneralChecking the camera is connecte or not Pin
Deepu Antony20-Dec-07 22:26
Deepu Antony20-Dec-07 22:26 
General"imapi.h" file missing - SDK version Pin
palanirajan20-Dec-07 22:04
palanirajan20-Dec-07 22:04 
GeneralRe: "imapi.h" file missing - SDK version Pin
ashishbhatt20-Dec-07 22:12
ashishbhatt20-Dec-07 22:12 
GeneralRe: "imapi.h" file missing - SDK version Pin
Cedric Moonen20-Dec-07 22:27
Cedric Moonen20-Dec-07 22:27 
Generalsystem tray - right click option Pin
Paulraj G20-Dec-07 21:28
Paulraj G20-Dec-07 21:28 
GeneralRe: system tray - right click option Pin
ashishbhatt20-Dec-07 21:47
ashishbhatt20-Dec-07 21:47 
GeneralRe: system tray - right click option Pin
Paulraj G20-Dec-07 23:27
Paulraj G20-Dec-07 23:27 
AnswerRe: system tray - right click option Pin
rajneshmalik21-Dec-07 0:32
rajneshmalik21-Dec-07 0:32 
GeneralRe: system tray - right click option Pin
Mark Salsbery21-Dec-07 8:36
Mark Salsbery21-Dec-07 8:36 
QuestionSTL, or MFC's Array/List? Pin
code_discuss20-Dec-07 20:42
code_discuss20-Dec-07 20:42 
GeneralRe: STL, or MFC's Array/List? PinPopular
Christian Graus20-Dec-07 21:09
protectorChristian Graus20-Dec-07 21:09 
AnswerRe: STL, or MFC's Array/List? Pin
Rajith21-Dec-07 20:45
Rajith21-Dec-07 20:45 
GeneralEncode/Decode audio/video using avcodec Pin
Don Box20-Dec-07 20:02
Don Box20-Dec-07 20:02 

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.