•
•
•
•
What is DaniWeb IT Discussion Community?
You're currently browsing the C++ section within the Software Development category of DaniWeb, a massive community of 361,561 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 2,022 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our C++ advertiser:
Views: 270 | Replies: 7 | Solved
![]() |
•
•
Join Date: Feb 2008
Posts: 404
Reputation:
Rep Power: 1
Solved Threads: 0
I have a Form witch scrollbars that is called Form2.
Is there any way to programatically go to the top of the Form without having to scrollup with the mouse ?
So if you have scrolled down to the end of the form. Is it possible to press a button that consist code that will go to the top of the Form2 ?
Is there any way to programatically go to the top of the Form without having to scrollup with the mouse ?
So if you have scrolled down to the end of the form. Is it possible to press a button that consist code that will go to the top of the Form2 ?
•
•
Join Date: Oct 2007
Location: Cherry Hill, NJ
Posts: 1,687
Reputation:
Rep Power: 9
Solved Threads: 160
•
•
Join Date: Feb 2008
Posts: 404
Reputation:
Rep Power: 1
Solved Threads: 0
I am trying to use this code to programatically scroll the Form2 to the top but this does not work. I think I missing something ?
Form2::VerticalScroll->Maximum;
Last edited by Jennifer84 : May 12th, 2008 at 9:11 am.
•
•
Join Date: Oct 2007
Location: Cherry Hill, NJ
Posts: 1,687
Reputation:
Rep Power: 9
Solved Threads: 160
•
•
Join Date: Feb 2008
Posts: 404
Reputation:
Rep Power: 1
Solved Threads: 0
I am not sure if I understand.
If I write Form2::VerticalScroll I cant find ClientOrigin or position as members.
I can“t find position or ClientOrigin as member to Form2:: either, so I think I am a bit stuck.
If I write Form2::VerticalScroll I cant find ClientOrigin or position as members.
I can“t find position or ClientOrigin as member to Form2:: either, so I think I am a bit stuck.
> I am not sure if I understand.
Ed was afraid that might happen. Duoas isn't describing Windows Forms, so his suggestions won't work for you. The code you want is
Ed was afraid that might happen. Duoas isn't describing Windows Forms, so his suggestions won't work for you. The code you want is
Form2::VerticalScroll->Value = 0; , but if Ed remembers correctly, that won't work as well as you probably want with the autoscrolling properties of a form. Last edited by Radical Edward : May 12th, 2008 at 3:00 pm.
Subtlety is the art of saying what you think and getting out of the way before it is understood.
•
•
Join Date: Oct 2007
Location: Cherry Hill, NJ
Posts: 1,687
Reputation:
Rep Power: 9
Solved Threads: 160
Ed is close. Jennifer is using C++Builder.
You can set
My apologies on ClientOrigin. I just looked it up and it is a read-only property. Alas.
Keep in mind my capitalization might be a little off.
I admire your tenacity and efforts, but either your documentation really stinks or you still need to work on searching it. (I just got BDS 2006 and it's documentation really stinks.)
Hope this helps.
You can set
Form2::VertScrollBar->Position = 0;My apologies on ClientOrigin. I just looked it up and it is a read-only property. Alas.
Keep in mind my capitalization might be a little off.
I admire your tenacity and efforts, but either your documentation really stinks or you still need to work on searching it. (I just got BDS 2006 and it's documentation really stinks.)
Hope this helps.
Last edited by Duoas : May 12th, 2008 at 6:25 pm.
•
•
Join Date: Feb 2008
Posts: 404
Reputation:
Rep Power: 1
Solved Threads: 0
No problem. I am using this code now and it seems to work fine for this purpose.
Thank you...
Thank you...
Form2::VerticalScroll->Value = 0;
•
•
•
•
Ed is close. Jennifer is using C++Builder.
You can set
Form2::VertScrollBar->Position = 0;
My apologies on ClientOrigin. I just looked it up and it is a read-only property. Alas.
Keep in mind my capitalization might be a little off.
I admire your tenacity and efforts, but either your documentation really stinks or you still need to work on searching it. (I just got BDS 2006 and it's documentation really stinks.)
Hope this helps.
![]() |
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
•
•
•
•
•
•
•
•
DaniWeb C++ Marketplace
Similar Threads
- Abnormal Behaviour of Vertical ScrollBar (VB.NET)
- Scrollbar in Form (VB6.0) (Visual Basic 4 / 5 / 6)
- changing the color of a HTML form selection (HTML and CSS)
Other Threads in the C++ Forum
- Previous Thread: Reversing a linked list using Recursion
- Next Thread: this->form2instance.Show();



Linear Mode