Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Form start position

I have a form called "switchboard" in an excel personal.xls file.

I have another file that has a button that calls the macro "OpenSB"
which essentially contains the code:

"Switchboard.show"

There are a couple of choices in the properties for the startu
position of this form, but I would like it in a different position (
little left of center actually).

I know the properties startupposition needs to be on manual, but othe
than that how do I control the form's position more?

1. What code
2. Where that code belongs (I get confused about where I should b
putting the code, I guess it should go in the personal.xls MainModule


And what about load or unload? Is that needed? If so why, and wher
should it go?

Thanks for any help you can offer.

Dre

--
Message posted from http://www.ExcelForum.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,080
Default Form start position

You can experiment to see where you want the form positioned. The code goes
in the UserForm module:

Private Sub UserForm_Activate()
Top = 200
Left = 200
End Sub

Your Show command will automatically load the UserForm; there is no need for
a separate Load statement.

To unload the form, use:

Unload Me

if in the UserForm module, or:

Unload Switchboard

if in another module.

--

Vasant



"drewdog " wrote in message
...
I have a form called "switchboard" in an excel personal.xls file.

I have another file that has a button that calls the macro "OpenSB",
which essentially contains the code:

"Switchboard.show"

There are a couple of choices in the properties for the startup
position of this form, but I would like it in a different position (a
little left of center actually).

I know the properties startupposition needs to be on manual, but other
than that how do I control the form's position more?

1. What code
2. Where that code belongs (I get confused about where I should be
putting the code, I guess it should go in the personal.xls MainModule.


And what about load or unload? Is that needed? If so why, and where
should it go?

Thanks for any help you can offer.

Drew


---
Message posted from http://www.ExcelForum.com/



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Form start position

Vasant:

Wow! It actually works. Can't thank you enough man. This was bugging m
big time.

Dre

--
Message posted from http://www.ExcelForum.com

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do set/ fix the opening position of a user form DataBoy Excel Discussion (Misc queries) 0 September 28th 09 07:29 PM
OT :Start your own online business today !start making dollars [email protected] Excel Discussion (Misc queries) 0 May 6th 06 09:29 PM
How do I create a button on the toolbar that will start my form? DMB Excel Discussion (Misc queries) 0 January 8th 06 11:00 PM
Lookup with search range start based on position of last blank lin rcmodelr Excel Worksheet Functions 0 November 14th 04 06:32 AM
can we start form by clicking hiperlink ? Konrad[_4_] Excel Programming 1 October 27th 03 07:45 PM


All times are GMT +1. The time now is 05:36 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"