473,394 Members | 1,769 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Need a command for scrolling in continuous form.

176 100+
Hello.

I would like to replace the defalt Scroll Bars with custom buttons in a continuous form.

I've tryed to make command buttons with the goto next/previous record macros, but those aren't acting in the same way as the scroll bars, for example, the control has to be focused in order for the goto next/previous record macros to work.

So, is there a way to compose a buttons that will imitate the scroll bar?

Much thanks, Michael.
Jan 29 '07 #1
4 8415
ADezii
8,834 Expert 8TB
Hello.

I would like to replace the defalt Scroll Bars with custom buttons in a continuous form.

I've tryed to make command buttons with the goto next/previous record macros, but those aren't acting in the same way as the scroll bars, for example, the control has to be focused in order for the goto next/previous record macros to work.

So, is there a way to compose a buttons that will imitate the scroll bar?

Much thanks, Michael.
The simplest way to mimic the scrolling behavior on a Continuous Form via Command Buttons is as follows:
Expand|Select|Wrap|Line Numbers
  1. 'In the Click() Event of a Command Button in the Form Footer with the
  2. Caption Scroll Up, place the following single line of code
  3. Private Sub cmdScrollUp_Click()
  4.   SendKeys "{PGUP}"
  5. End Sub
Expand|Select|Wrap|Line Numbers
  1. 'In the Click() Event of a Command Button in the Form Footer with the
  2. Caption Scroll Down, place the following single line of code
  3. Private Sub cmdScrollDown_Click()
  4.   SendKeys "{PGDN}"
  5. End Sub
Jan 29 '07 #2
NeoPa
32,556 Expert Mod 16PB
I think that to imitate the scrollbars with full-functionality is actually quite involved as there are various things the scroll bars respond to :
Clicking above / below; dragging; keystrokes; etc.
Some of the more important (to you) functionality can be mimicked but it's quite detailed work.
Jan 29 '07 #3
ADezii
8,834 Expert 8TB
I think that to imitate the scrollbars with full-functionality is actually quite involved as there are various things the scroll bars respond to :
Clicking above / below; dragging; keystrokes; etc.
Some of the more important (to you) functionality can be mimicked but it's quite detailed work.
It would seem as though imitating fully functional Scroll Bars via Command Buttons would be next to impossible until I had a brainstorm. What do you think about using the Auto Repeat property of a Command Button? As long as this Property is set to True, code within the Click() Event of the button will execute as long as the button is pressed. With an appropriate delay factor programmed in to slow down Record Navigation, it may not be as difficult as we think. Of course the other factors that you mentioned such as Clicking above / below; dragging; keystrokes would be next to impossible to duplicate. Checking for BOF and EOF would probably be difficult also because of the Repeat factor. Please excuse me if I am ranting on - just wanted your input.
Jan 29 '07 #4
NeoPa
32,556 Expert Mod 16PB
Not at all ADezii, I'm always pleased to discuss matters towards anyone's better understanding (mine included).
Let me first issue another request to initiate Private Message contact though. Can you let me know if you have any difficulty with this (in here or by PM).
Certainly the auto-repeat feature could add similarity to the effect. I would also say that PageUp & PageDown controls could also be added in such a way as to look like the scroll bar. I wouldn't do it myself unless for an exercise, and I wouldn't want to take someone through it on here unless they could communicate well.
I've implemented record level controls on a bound form before to replace the defaults but I would see Scroll bars as an extra level of complication.
Jan 29 '07 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Richard Hollenbeck | last post by:
The only reason I made the continuous forms form into a subform is because I like the scrolling behavior better. For example, I don't like how the vertical scrollbar spans the height of the entire...
3
by: Typehigh | last post by:
I am a good programmer, but this one stumps me! I have a form with a continuous subform. The continuous subform contains records of data and may reach a depth of 1000's of entities. I have...
4
by: John Smith | last post by:
I have a continuous form. there is a command button with the following code for the OnClick event: DoCmd.OpenForm "frmPlants", , , "PlantsID =" & Me!PlantsID I click the button and frmPlants...
0
by: avanti | last post by:
How can I achieve continuous scrolling with a vertical scrollbar in C#? Thanks, Avanti
2
by: Wayne | last post by:
Is there a workaround to the bug that loses the first record in a continuous form after using the scroll wheel if the available records don't fill the form? I know that the "up arrow" section of...
7
by: Dave | last post by:
Hello All, These one may be a bit tricky, and what I'd like to do may not even be possible. I would love to hear any ideas you guys have for solving this. Here is the situation: I have a form...
1
by: lennyc | last post by:
I would like to make a simple auto scroll of images with little user interactioin. It would be images moving horizontally in a continuous loop that stops on mouse over and starts up again on mouse...
2
by: Steve | last post by:
I have a continuous form showing Product Code and Product Name. Product Code is five digits and is sequential. I have a textbox in the form header. What is the code to scroll the continuous form so...
7
by: Kevin Wilcox | last post by:
Hi I'm trying to emulate, within access, the gantt chart timeline / task planner aspects of ms project. Creating the chart on the form has been easy enough; I use a series of unbound text boxes in...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.