Dialog "Position" properties ver 12

Hints, tips and tricks for newbies

Moderators: Dorian (MJT support), JRL

Post Reply
delta1
Junior Coder
Posts: 26
Joined: Wed Dec 16, 2009 11:23 pm

Dialog "Position" properties ver 12

Post by delta1 » Tue Jun 01, 2010 10:29 pm

I am having trouble figuring out the last four choices of the position property for a dialog (form). I am trying to get a borderless dialog at the top of my screen and about 400 pixels to the right for a some custom buttons. I have checked help and the manual.
The manual says: "Position Represents the size and placement of the form."
Thanks.

adroege
Automation Wizard
Posts: 438
Joined: Tue Dec 07, 2004 7:39 pm

Post by adroege » Wed Jun 02, 2010 12:51 am

I haven't played with version 12 yet....however in a code sample I found the following:
Position = poScreenCenter
I assume the dialog designer has a combo box for this property, which lists all the available choices? This would be my guess without seeing it first hand.

Hopefully this gives you some clues....

User avatar
Marcus Tettmar
Site Admin
Posts: 7395
Joined: Thu Sep 19, 2002 3:00 pm
Location: Dorset, UK
Contact:

Post by Marcus Tettmar » Wed Jun 02, 2010 9:03 am

Set Position to poDefault and then use Left and Top properties to set the exact position you want.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?

delta1
Junior Coder
Posts: 26
Joined: Wed Dec 16, 2009 11:23 pm

Post by delta1 » Wed Jun 02, 2010 2:12 pm

That is what I did. MS does not seem to be reading the "left" property. Left is set at 366 and yet the dialog appears at 0. Also when updated to the code window left appears as 266??
http://5sd1yq.blu.livefilestore.com/y1p ... 20test.png

User avatar
Marcus Tettmar
Site Admin
Posts: 7395
Joined: Thu Sep 19, 2002 3:00 pm
Location: Dorset, UK
Contact:

Post by Marcus Tettmar » Wed Jun 02, 2010 2:58 pm

Do this:

SetDialogProperty>Dialog1,,Left,800
SetDialogProperty>Dialog1,,Top,10

Show>Dialog1,r

(Change dialog name and position values accordingly)
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?

delta1
Junior Coder
Posts: 26
Joined: Wed Dec 16, 2009 11:23 pm

Post by delta1 » Wed Jun 02, 2010 4:05 pm

Thanks, that works.

Post Reply
Sign up to our newsletter for free automation tips, tricks & discounts