Results 1 to 11 of 11

Thread: [2008] transparency for users

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Nov 2008
    Posts
    413

    [2008] transparency for users

    is there any way to allow the user to set the transparency of the windows?
    If so, what sort of commands am I looking to use?

    Dan

  2. #2
    Stack Overflow mod​erator
    Join Date
    May 2008
    Location
    British Columbia, Canada
    Posts
    2,824

    Red face Re: [2008] transparency for users

    What do you mean "let the user set"? Are you going to use a textbox control? Is it a windows forms app? If the answer to both those questions is yes then this is the code.

    Code Code:
    1. Private Sub txtControl.Leave(sender,e) Handles txtControl.Leave 'This is whatever event you want
    2.        Me.Opacity = Val(Me.txtControl.Text)
    3. End Sub

  3. #3

    Thread Starter
    Hyperactive Member
    Join Date
    Nov 2008
    Posts
    413

    Re: [2008] transparency for users

    it is a web browser (windows form)
    And I was thinking of having a "slider" to change the transparency of buttons and so on

  4. #4
    Stack Overflow mod​erator
    Join Date
    May 2008
    Location
    British Columbia, Canada
    Posts
    2,824

    Unhappy Re: [2008] transparency for users

    Ok, a web browser. The buttons on the web page or the buttons on your browser? If it's on the web page, then I can't help you. Also, I'm not sure if the controls in VS 2008 have very different controls or new ones from VS 2005.
    Sorry.

  5. #5

    Thread Starter
    Hyperactive Member
    Join Date
    Nov 2008
    Posts
    413

    Re: [2008] transparency for users

    buttons on the browser, dont be sorry you are still here trying to help

  6. #6
    Frenzied Member obi1kenobi's Avatar
    Join Date
    Aug 2007
    Posts
    1,091

    Re: [2008] transparency for users

    Use the TrackBar control (it's a slider) and handle the ValueChanged event (I think that was it's name) to set the Opacity property of the appropriate controls.
    Please rate helpful ppl's posts. It's the best 'thank you' you can give

  7. #7

    Thread Starter
    Hyperactive Member
    Join Date
    Nov 2008
    Posts
    413

    Re: [2008] transparency for users

    ok thank you you got the name of the event right by the way
    It'd be similar to setting the colour then:P

  8. #8
    Stack Overflow mod​erator
    Join Date
    May 2008
    Location
    British Columbia, Canada
    Posts
    2,824

    Thumbs up Re: [2008] transparency for users

    Oh. In VS 2005, each control does not have its own Opacity property.
    Sorry.









    *********************************************************
    Just for anybody who might want their buttons special on their browser, you can always draw semitransparent graphic "buttons" in the Paint event, and handle them with the mousemove (for mouseovers) and mouseclick events.

  9. #9

    Thread Starter
    Hyperactive Member
    Join Date
    Nov 2008
    Posts
    413

    Re: [2008] transparency for users

    well, i have tried what you sed, and it seems like it might work, i just have to tell the transparency to operate on different things

  10. #10
    Frenzied Member obi1kenobi's Avatar
    Join Date
    Aug 2007
    Posts
    1,091

    Re: [2008] transparency for users

    Quote Originally Posted by danielpalfrey
    well, i have tried what you sed, and it seems like it might work, i just have to tell the transparency to operate on different things
    I didn't quite understand the underlined part...
    Please rate helpful ppl's posts. It's the best 'thank you' you can give

  11. #11

    Thread Starter
    Hyperactive Member
    Join Date
    Nov 2008
    Posts
    413

    Re: [2008] transparency for users

    basically, if I want it to set transparency on 3 buttons, then I use the specific names of those 3 buttons under 1 private sub.

    Code:
    transperency.button1 = slidebar.ok
    transperency.button2 = slidebar.ok
    transperency.button3 = slidebar.ok
    above is an example of what the code could look like, it isnt this, but it is an example of what could be under the private sub

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