Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2

Thread: Button

  1. #1
    New Coder
    Join Date
    Jul 2002
    Location
    Malaysia
    Posts
    61
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Button

    Dear Sir,

    In VB 6.0, I create a button called cmdoption. How can I put the picture in the left of the cmdoption and text in the right of the cmdoption?


    Thanks


    Xiang

  • #2
    Regular Coder
    Join Date
    Dec 2003
    Posts
    367
    Thanks
    0
    Thanked 0 Times in 0 Posts
    You have to set the Style of the button to Graphical, set the Picture property to the picture you want, and the Caption to the text you want. But, AFAIK, the text will appear below the picture and not on the right. There is no easy way to get the text on the right. I think it's only possible using owner-drawn controls, but that is quite an advanced topic.
    What you could try is using a picture file that is transparent on it's right side, and put many spaces in the beginning of the caption, but that's quite an ugly hack.

    shmoove


  •  

    Posting Permissions

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