Link to home
Start Free TrialLog in
Avatar of Didsi
Didsi

asked on

Stop userform moving - Visual basic

How can i prevent a userform being 'dragged' or moved in visual basic? i have office 2007, visual basic 6.5. I have read there is a "movable" property whch i could change to false, however i cannot see it. Anybody able to help?!

Many Thanks
Avatar of ExcelGuide
ExcelGuide
Flag of Netherlands image

Avatar of utter77
utter77

Hi. in vb6.0 you have a property on the form, Moveable. Set it to False.

/MAtt
Avatar of Didsi

ASKER

cant find the moveable option!
Avatar of Chris Bottomley
Hello Didsi,

Right click on teh form and select properties.

In teh properties window in the editor you can scroll down in teh alphabetic tab until the moveable proerty is displayed.  DOuble clicking in the adjacent window will toggle between true and false.  A value of false prevents the form being moved.

Regards,

chris_bottomley
Avatar of Didsi

ASKER

The moveable property is not there, do i have to do as psycotec said and create a class or is there a way of showing the moveable property
Can you set the property in form_load?

Me.Moveable = false
WHat kind of VB project are you creating?

Chris
Avatar of Didsi

ASKER

"userform_load
Me.Moveable = False"      Does not work.

The VB project is a signing in/out system. Dont want the user to be able to move the userform
In the VB editor, click project | properties.

What is displayed in the General tab for the project type?  Note I have no sight of a cause as yet just trying to understand the setup to try and reproduce your obervation.

Chris
Avatar of Didsi

ASKER

Do you mean right click and properties on the VBA prject, if so the theres is no project type tab
I see now you are referring to VBA not VB sorry I missed that - I don't think you can freeze the position of a VBA form but i'll look a while and maybe someone will have an idea.

Chris
ASKER CERTIFIED SOLUTION
Avatar of Didsi
Didsi

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial