Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Make form activate at top of form, not centered

Status
Not open for further replies.

ehicks727

Programmer
Joined
Oct 26, 2004
Messages
36
Location
US
I'm helping someone fix some forms they created. The form exceeds the screen length and it activates centered. This is a maximized form and I asked if they can make everything fit into 1024x768 and they couldn't. So the problem is that everytime the form opens, the user has to use the scrollbar to get to the top of the form.

I know this isn't the best way to handle this, but it's not my program.

thanks for the suggestions.
 
The only way I can get a form to do what you describe is to have the Load event set the focus on a control that is below the window line.

What control has the focus when the form loads? Is this a continuous form or a single form? Can you have the focus set to a control at the top of the form on the Load or Activate event?



John

Use what you have,
Learn what you can,
Create what you need.
 
The tab focus did the trick! thank you for your help. I didn't realize it was that simple :)
 
Glad to help.

FYI, if your form is not maximized, you can use the Move method to set the Left, Top, Width & Height properties. Comes in handy if you want to have forms or reports opening side by side.



John

Use what you have,
Learn what you can,
Create what you need.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top