Community discussion forum

Binding Controls to Setting

  • 2 years ago

    Hi All,

    I want to control the visible property of a button control on a form using a setting e.g. My.Settings.ButtonVisible. I have added the My.Settings as a data source and bound the property to it. It doesn't work!

    Is there something else I need to do to make the visible property take the boolean setting value?

    The last three times I left a post on here I never got a single reply, is anyone still reading these posts?

     

  • 2 years ago

     Make it in that button... create inherited class where is new property exposing real visbility but beeing Loaded and Save to My.Settings, also think about using more buttons like that.

  • 2 years ago

    OK so no-one is reading these posts.

    I have been a member for ages and seen this site go downhill very rapidly. All my posts were answered and I answered dozens of posts, hopefully helping people in the process (I even built an app for one guy). This is very sad and I hope the situation improves soon but for now I will say adieu

    Dur dur durrrrrr (you cant hear it but I am playing the last post, sorry)

    Bye

  • 2 years ago

    I prefer databinding using the Binding object. Don't ask me why, it just seems to code better.

    Such as:

    Dim cust as New Customer()

    TextBox1.DataBindings(New Binding("tbProperty", cust, "custProperty"))

     This way you can use row based or set  based programming logic.

Post a reply

Enter your message below

Sign in or Join us (it's free).

We'd love to hear what you think! Submit ideas or give us feedback