Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. UserControl Development and the StyleChanged Event

UserControl Development and the StyleChanged Event

Scheduled Pinned Locked Moved Visual Basic
wpftutorial
8 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • G Offline
    G Offline
    Graham Irons
    wrote on last edited by
    #1

    I'm developing a UserControl and I need to know when a user has changed the BorderStyle of the UserControl. I know that this is trapped in the UserControl's StyleChanged Event. But, I don't know how to determine which of the Control's Styles has changed and what it has changed to. Does anyone have a code sample that would demonstrate this Event please.

    Regards, Graham

    V 1 Reply Last reply
    0
    • G Graham Irons

      I'm developing a UserControl and I need to know when a user has changed the BorderStyle of the UserControl. I know that this is trapped in the UserControl's StyleChanged Event. But, I don't know how to determine which of the Control's Styles has changed and what it has changed to. Does anyone have a code sample that would demonstrate this Event please.

      Regards, Graham

      V Offline
      V Offline
      V 2
      wrote on last edited by
      #2

      Hi, First Each n every control has its own style changed event if u still facing the problem in it then check the fous or active control in your form , One the control has focused=true n active means that control's border sytle has changed.... Hope this will help U

      Unless u don't give ur hundred percent whatever u r doing till there is no result of ur work...

      G 1 Reply Last reply
      0
      • V V 2

        Hi, First Each n every control has its own style changed event if u still facing the problem in it then check the fous or active control in your form , One the control has focused=true n active means that control's border sytle has changed.... Hope this will help U

        Unless u don't give ur hundred percent whatever u r doing till there is no result of ur work...

        G Offline
        G Offline
        Graham Irons
        wrote on last edited by
        #3

        I think that I'm too simple to understand all of this. Could you please translate this into something like English. I can also speak French if that is easier for you. :(

        Regards, Graham

        V M 2 Replies Last reply
        0
        • G Graham Irons

          I think that I'm too simple to understand all of this. Could you please translate this into something like English. I can also speak French if that is easier for you. :(

          Regards, Graham

          V Offline
          V Offline
          V 2
          wrote on last edited by
          #4

          Which thing is difficult to understand my english or the meaning of this what i said??? Which default control your are using to create a new user control???? There is 3 methods of doing this 1> Take default control eg textbox n add new features to create new textbox usercontrol 2>Use more than 1 control to create new user control 3>Create own user control without using any default So which method you are using and which control??? May be i help u because i have also created user control before some time....

          Unless u don't give ur hundred percent whatever u r doing till there is no result of ur work...

          M G 2 Replies Last reply
          0
          • G Graham Irons

            I think that I'm too simple to understand all of this. Could you please translate this into something like English. I can also speak French if that is easier for you. :(

            Regards, Graham

            M Offline
            M Offline
            Mycroft Holmes
            wrote on last edited by
            #5

            What the keyboard challenged is trying to say is that each of your objects within the control has a border. If it is the UC borderchange event then I beleive it will be the UC container. If you change the border on a textbox within the UC does the event for the UC fire. If so then as ~V~ said chek the current active control inside the UC.

            Never underestimate the power of human stupidity RAH

            G 1 Reply Last reply
            0
            • V V 2

              Which thing is difficult to understand my english or the meaning of this what i said??? Which default control your are using to create a new user control???? There is 3 methods of doing this 1> Take default control eg textbox n add new features to create new textbox usercontrol 2>Use more than 1 control to create new user control 3>Create own user control without using any default So which method you are using and which control??? May be i help u because i have also created user control before some time....

              Unless u don't give ur hundred percent whatever u r doing till there is no result of ur work...

              M Offline
              M Offline
              Mycroft Holmes
              wrote on last edited by
              #6

              Seemed pretty clear to me, mind you your sig says it all - drop 10 characters from a sentence and make it difficult to read!

              Never underestimate the power of human stupidity RAH

              1 Reply Last reply
              0
              • V V 2

                Which thing is difficult to understand my english or the meaning of this what i said??? Which default control your are using to create a new user control???? There is 3 methods of doing this 1> Take default control eg textbox n add new features to create new textbox usercontrol 2>Use more than 1 control to create new user control 3>Create own user control without using any default So which method you are using and which control??? May be i help u because i have also created user control before some time....

                Unless u don't give ur hundred percent whatever u r doing till there is no result of ur work...

                G Offline
                G Offline
                Graham Irons
                wrote on last edited by
                #7

                What is difficult is the abreviations you are using. I'm 68 years old and all of the younger generation words are foreign to me. Please be explicit. English or French is OK with me. ;)

                Regards, Graham

                1 Reply Last reply
                0
                • M Mycroft Holmes

                  What the keyboard challenged is trying to say is that each of your objects within the control has a border. If it is the UC borderchange event then I beleive it will be the UC container. If you change the border on a textbox within the UC does the event for the UC fire. If so then as ~V~ said chek the current active control inside the UC.

                  Never underestimate the power of human stupidity RAH

                  G Offline
                  G Offline
                  Graham Irons
                  wrote on last edited by
                  #8

                  Thank you. Now I'm closer to the solution. I'll test with that and get back to you.

                  Regards, Graham

                  1 Reply Last reply
                  0
                  Reply
                  • Reply as topic
                  Log in to reply
                  • Oldest to Newest
                  • Newest to Oldest
                  • Most Votes


                  • Login

                  • Don't have an account? Register

                  • Login or register to search.
                  • First post
                    Last post
                  0
                  • Categories
                  • Recent
                  • Tags
                  • Popular
                  • World
                  • Users
                  • Groups