Saving & restoring vertical scroll position of a form.

J

JerryG

I have a form with 12 subforms that scroll vertically, used in a medical
scheduling application.

When an appointment is added I save the strSQL that pertains to the subform
that initiated the request to a public string.

The subform fires the timer event and checks the public string to see it it
is not = "". If true, it makes its rowsource = the public string, requeries,
and makes the public string = "".

Problem: how can I save the vertical scroll position, so that after the
requery I can restore the vertical position to where it was before the
requery.
 
B

BruceM

You could probably set the focus to a particular control. However, doesn't
the requery bring you back to the first record? Or are you talking about
requerying a combo box row source (you mention making the row source equal
the public string, which sounds as if you are talking about a combo box or a
list box).
It may help if you describe the purpose of the subforms, and include the
code you use. It is not readily apparent what you mean when you say you
save the strSQL. What strSQL is that? Where did it come from? How do you
save it? How does the subform initiate the request, and what request is
that?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top