Click here to Skip to main content
15,922,512 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionCan MSVS 6 leverage .net (more precisely C# forms)? Pin
-e22-Apr-06 2:30
-e22-Apr-06 2:30 
AnswerRe: Can MSVS 6 leverage .net (more precisely C# forms)? Pin
toxcct22-Apr-06 7:07
toxcct22-Apr-06 7:07 
GeneralRe: Can MSVS 6 leverage .net (more precisely C# forms)? Pin
-e22-Apr-06 12:42
-e22-Apr-06 12:42 
AnswerRe: Can MSVS 6 leverage .net (more precisely C# forms)? Pin
Waldermort22-Apr-06 8:17
Waldermort22-Apr-06 8:17 
GeneralRe: Can MSVS 6 leverage .net (more precisely C# forms)? Pin
-e22-Apr-06 13:02
-e22-Apr-06 13:02 
AnswerRe: Can MSVS 6 leverage .net (more precisely C# forms)? Pin
Michael P Butler23-Apr-06 7:57
Michael P Butler23-Apr-06 7:57 
QuestionScroll Window without document/view Pin
mwybranczyk22-Apr-06 1:34
mwybranczyk22-Apr-06 1:34 
AnswerRe: Scroll Window without document/view Pin
includeh1022-Apr-06 4:08
includeh1022-Apr-06 4:08 
As i know, no suvh class.
acturally u do'nt need to find it, scroll is easy to do:
1.add scroll-bars if neccessary.
2.show/hide and manage scrolling by a little bit code.

//follwings are my code for your reference
//bar_Vert and bar_Horz are added on a prperty-page

void SheetPreviewPgGragh::OnVScroll(UINT nSBCode, UINT nPos, CScrollBar* pScrollBar)
{
CPropertyPage::OnVScroll(nSBCode, nPos, pScrollBar);
if(pScrollBar!=&bar_Vert) return;
P_ScrollBar(nSBCode,nPos,pScrollBar);
}

void SheetPreviewPgGragh::OnHScroll(UINT nSBCode, UINT nPos, CScrollBar* pScrollBar)
{
CPropertyPage::OnHScroll(nSBCode, nPos, pScrollBar);
if(pScrollBar!=&bar_Horz) return;
P_ScrollBar(nSBCode,nPos,pScrollBar);
}

void SheetPreviewPgGragh::P_ScrollBar(int iCode, int iPosIn,CScrollBar*pBar)
{
SCROLLINFO si;
si.cbSize =sizeof(SCROLLINFO);
si.fMask=SIF_ALL;
pBar->GetScrollInfo(&si);

int iPos =si.nPos;

switch(iCode)
{
case SB_LINEUP:
iPos-=1;
break;
case SB_LINEDOWN:
iPos+=1;
break;

case SB_PAGEUP:
iPos-=si.nPage;
break;
case SB_PAGEDOWN:
iPos+=si.nPage;
break;
case SB_THUMBTRACK:
iPos=iPosIn;
break;
}

if(iPos<0) iPos=0;
if(iPos>(int)(si.nMax-si.nPage)) iPos=si.nMax-si.nPage+1;
if(iPos==si.nPos) return;

si.nPos=iPos;
pBar->SetScrollInfo(&si);
RedrawPage();
}



A special image tool for C++ programmers, don't miss it!
The world unique Software Label Maker is here for you and me ...
A nice
hyper tool for optimizing your MS html-help contents.


QuestionListbox control Pin
srija22-Apr-06 1:26
srija22-Apr-06 1:26 
AnswerRe: Listbox control Pin
Gary R. Wheeler22-Apr-06 2:11
Gary R. Wheeler22-Apr-06 2:11 
GeneralRe: Listbox control Pin
srija22-Apr-06 5:18
srija22-Apr-06 5:18 
GeneralRe: Listbox control Pin
Bram van Kampen22-Apr-06 15:49
Bram van Kampen22-Apr-06 15:49 
GeneralRe: Listbox control Pin
srija23-Apr-06 7:02
srija23-Apr-06 7:02 
Questionreading strings from file - newbie Pin
antonaras_marcou22-Apr-06 1:23
antonaras_marcou22-Apr-06 1:23 
AnswerRe: reading strings from file - newbie Pin
Stephen Hewitt22-Apr-06 1:46
Stephen Hewitt22-Apr-06 1:46 
GeneralRe: reading strings from file - newbie Pin
antonaras_marcou22-Apr-06 2:07
antonaras_marcou22-Apr-06 2:07 
GeneralRe: reading strings from file - newbie Pin
Stephen Hewitt22-Apr-06 2:10
Stephen Hewitt22-Apr-06 2:10 
AnswerRe: reading strings from file - newbie Pin
Michael Dunn22-Apr-06 9:12
sitebuilderMichael Dunn22-Apr-06 9:12 
GeneralRe: reading strings from file - newbie Pin
Stephen Hewitt22-Apr-06 18:51
Stephen Hewitt22-Apr-06 18:51 
QuestionPlacing transparent bitmaps into dialogs Pin
Rafael Fernández López22-Apr-06 1:04
Rafael Fernández López22-Apr-06 1:04 
AnswerRe: Placing transparent bitmaps into dialogs Pin
John R. Shaw22-Apr-06 18:37
John R. Shaw22-Apr-06 18:37 
QuestionProperty Sheet Problem Pin
si_6921-Apr-06 23:42
si_6921-Apr-06 23:42 
AnswerRe: Property Sheet Problem Pin
includeh1022-Apr-06 4:40
includeh1022-Apr-06 4:40 
GeneralRe: Property Sheet Problem Pin
si_6922-Apr-06 11:58
si_6922-Apr-06 11:58 
Questionhow can i get my app path? Pin
Sina Parastgary21-Apr-06 23:29
Sina Parastgary21-Apr-06 23:29 

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.