Click here to Skip to main content
15,915,770 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Detection of OCX File Pin
Coremn2-Apr-03 15:34
Coremn2-Apr-03 15:34 
GeneralRe: Detection of OCX File Pin
Aisha Ikram3-Apr-03 17:56
Aisha Ikram3-Apr-03 17:56 
GeneralUse "SetDIBitsToDevice" to show JPEG image Pin
Tossporn1-Apr-03 15:10
Tossporn1-Apr-03 15:10 
GeneralUsing Old C libraries with C++ libraries Pin
dahicke1-Apr-03 14:15
dahicke1-Apr-03 14:15 
GeneralRe: Using Old C libraries with C++ libraries Pin
dahicke2-Apr-03 12:32
dahicke2-Apr-03 12:32 
GeneralTranslating Accelerator From Dialog to MainFrame :: MFC Pin
valikac1-Apr-03 14:14
valikac1-Apr-03 14:14 
QuestionScrolling edit control to bottom? Pin
IGx891-Apr-03 14:07
IGx891-Apr-03 14:07 
AnswerRe: Scrolling edit control to bottom? Pin
Gary R. Wheeler1-Apr-03 14:30
Gary R. Wheeler1-Apr-03 14:30 
CEdit edit_control;

edit_control.SetSel(0,-1,FALSE);
This will force the edit control to scroll the last line into view whenever you add more text.

You need to be a little careful in how you use this. Each time you do this, you'll scroll the control down, even if the user was trying to scroll the control himself. A simple solution is to have a check box off to the side, perhaps labelled "update". If the update box is checked, you scroll the last line into place. If it's not checked, assume that the user is looking at the data, and doesn't want the scrolling to happen. You can still update the text in the edit control in this case, although you may need to make sure you save the user's selection (GetSel() and SetSel()) and restore it after you update the text.


Software Zen: delete this;
GeneralRe: Scrolling edit control to bottom? Pin
IGx891-Apr-03 14:40
IGx891-Apr-03 14:40 
QuestionPurify or BoundsChecker? Pin
Jon Sagara1-Apr-03 13:45
Jon Sagara1-Apr-03 13:45 
AnswerRe: Purify or BoundsChecker? Pin
dahicke1-Apr-03 13:55
dahicke1-Apr-03 13:55 
AnswerRe: Purify or BoundsChecker? Pin
Taka Muraoka1-Apr-03 13:58
Taka Muraoka1-Apr-03 13:58 
AnswerRe: Purify or BoundsChecker? Pin
Mustafa Demirhan1-Apr-03 21:20
Mustafa Demirhan1-Apr-03 21:20 
GeneralBN_CLICKED Pin
lucy1-Apr-03 11:52
lucy1-Apr-03 11:52 
GeneralRe: BN_CLICKED Pin
Gary R. Wheeler1-Apr-03 14:02
Gary R. Wheeler1-Apr-03 14:02 
GeneralRe: BN_CLICKED Pin
lucy2-Apr-03 5:22
lucy2-Apr-03 5:22 
GeneralMDI maximized & restored Pin
Brian Shifrin1-Apr-03 11:50
Brian Shifrin1-Apr-03 11:50 
GeneralPointer access Pin
Gabor Kalman1-Apr-03 11:13
Gabor Kalman1-Apr-03 11:13 
GeneralRe: Pointer access Pin
Dave Bryant1-Apr-03 11:29
Dave Bryant1-Apr-03 11:29 
GeneralSize of dialog in resource Pin
JGranborg1-Apr-03 10:56
JGranborg1-Apr-03 10:56 
GeneralRe: Size of dialog in resource Pin
Gary R. Wheeler1-Apr-03 14:08
Gary R. Wheeler1-Apr-03 14:08 
GeneralDynamic Arrays and Array sizes Pin
einst9921-Apr-03 10:41
einst9921-Apr-03 10:41 
GeneralRe: Dynamic Arrays and Array sizes Pin
Chris Losinger1-Apr-03 10:49
professionalChris Losinger1-Apr-03 10:49 
GeneralRe: Dynamic Arrays and Array sizes Pin
einst9921-Apr-03 11:33
einst9921-Apr-03 11:33 
GeneralRe: Dynamic Arrays and Array sizes Pin
Nick Parker1-Apr-03 11:56
protectorNick Parker1-Apr-03 11:56 

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.