Results 1 to 7 of 7

Thread: [RESOLVED] toolbar right to left

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Nov 2015
    Posts
    919

    Resolved [RESOLVED] toolbar right to left

    Hello
    I want to know if it is possible to make a toolbar in vb6 have the right to left property.
    If so what is the right code to that?
    Thank you
    Last edited by newbie2; Dec 27th, 2015 at 05:12 PM.

  2. #2
    PowerPoster
    Join Date
    Jan 2008
    Posts
    11,074

    Re: toolbar right to left

    What is right to left property? Is it button 1 on the right and last button on the left?


    Anything I post is an example only and is not intended to be the only solution, the total solution nor the final solution to your request nor do I claim that it is. If you find it useful then it is entirely up to you to make whatever changes necessary you feel are adequate for your purposes.

  3. #3
    PowerPoster
    Join Date
    Sep 2006
    Location
    Egypt
    Posts
    2,579

    Re: toolbar right to left

    There is no property do that, but it is possible to emulate the behavior by inserting a button of type Placeholder at the beginning and using the following code

    Code:
    Private Sub Form_Load()
        ' You can remove the following command if you inserted the button at design time
        Toolbar1.Buttons.Add 1, "", "", tbrPlaceholder
    End Sub
    
    Private Sub Form_Resize()
        ' Adjust the place holder button width when resizing the form to move all other buttons to the right edge
        Toolbar1.Buttons(1).Width = Me.ScaleWidth - ((Toolbar1.Buttons.Count - 1) * Toolbar1.ButtonWidth)
    End Sub



  4. #4

    Thread Starter
    Fanatic Member
    Join Date
    Nov 2015
    Posts
    919

    Re: toolbar right to left

    Thanks for the reply

    Now my buttons start from the left side of the toolbar and are terminated a bit after the middle.
    If I inverse the buttons, they will start for the middle of the toolbar and not from the right corner of the form.
    How can I set my first button at the beginning of the toolbar from the right?
    I wish you'd understand me

  5. #5

    Thread Starter
    Fanatic Member
    Join Date
    Nov 2015
    Posts
    919

    Re: toolbar right to left

    4x2y
    Thank you I'll try this method

  6. #6

    Thread Starter
    Fanatic Member
    Join Date
    Nov 2015
    Posts
    919

    Re: toolbar right to left

    4x2y
    Thanks a million it worked

  7. #7
    PowerPoster
    Join Date
    Sep 2006
    Location
    Egypt
    Posts
    2,579

    Re: [RESOLVED] toolbar right to left

    You are welcome



Posting Permissions

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



Click Here to Expand Forum to Full Width