Repositioning a control using Visual Basic

  • Thread starter Thread starter scott
  • Start date Start date
S

scott

I want to reposition some controls when I click a button and I'm not having
much luck. Any help is appreciated. The code I am using is
Me!Frame28.Top = 5.8646

It repositions the contro to the top of the form. If I try to add the inch
sign ("), of course it is looking for additional code to end the statement.
'"' doesn't work either.

Thanks.
 
scott said:
I want to reposition some controls when I click a button and I'm not having
much luck. Any help is appreciated. The code I am using is
Me!Frame28.Top = 5.8646

It repositions the contro to the top of the form. If I try to add the
inch
sign ("), of course it is looking for additional code to end the
statement.
'"' doesn't work either.


In VBA code, all measurements are in "twips". 1 twip = one-twentieth of a
point = 1/1440 inch. That is, there are 1440 twips in an inch. So if you
want to position the control's top at 5.8646 inches, you should write:

Me!Frame28.Top = 8445
 
Back
Top