Results 1 to 3 of 3
  1. #1
    3 Star Lounger
    Join Date
    Jan 2001
    Posts
    254
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Move left (Access 2000)

    What is the command to move controls? I have a control placed in the last of the row in a form.I want this control to
    be moved temporarily in the first place and take the place of an already invisible control.This invisible control hase a property
    left =0,099cm and i want to give such a command that my control CtrlBus takes the place of the first invisible control

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Move left (Access 2000)

    You can change the Left property of the control in code. In VBA, it is expressed in twips, where 1 inch = 1440 twips, or 1 cm = 567 twips (approximately). So to set the Left property of a control to 0.099 cm, you use

    Me.ControlName.Left = 56

    where ControlName is the name of the control.

    Notes:
    If the control name contains spaces (not recommended), put it between square brackets: [Control Name]
    If you want to use numbers with decimal places, you must use a decimal point in VBA.

  3. #3
    Gold Lounger
    Join Date
    Jun 2001
    Location
    Crystal Beach, FL, Florida, USA
    Posts
    3,436
    Thanks
    1
    Thanked 34 Times in 34 Posts

    Re: Move left (Access 2000)

    You could just set the Left and Top properties of the control you want to move to be equal to the values of the control you want to overlay, eliminating the need to convert. Like this: CtrlBus.Left = txtFirstControl.Left
    Mark Liquorman
    See my website for Tips & Downloads and for my Liquorman Utilities.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •