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. .NET (Core and Framework)
  4. [VB.NET 2008] How to detect if a page of a TabControl is selected (Windows CE)

[VB.NET 2008] How to detect if a page of a TabControl is selected (Windows CE)

Scheduled Pinned Locked Moved .NET (Core and Framework)
csharpvisual-studiohelptutorial
4 Posts 2 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.
  • S Offline
    S Offline
    steve_9496613
    wrote on last edited by
    #1

    Hi, I'm developing an application that runs in a Windows CE 5.0 environment and I'm using VB.NET in Visual Studio 2008 Pro. In a Form I have a TabControl with some pages. My problem is to understand when a page of the TabControl is selected to perform some actions in that page automatically. In the Compact Framework there isn't the event Control.Enter so I can't use it, that would be the right one... Does anyone have any idea? Thanks

    Z 1 Reply Last reply
    0
    • S steve_9496613

      Hi, I'm developing an application that runs in a Windows CE 5.0 environment and I'm using VB.NET in Visual Studio 2008 Pro. In a Form I have a TabControl with some pages. My problem is to understand when a page of the TabControl is selected to perform some actions in that page automatically. In the Compact Framework there isn't the event Control.Enter so I can't use it, that would be the right one... Does anyone have any idea? Thanks

      Z Offline
      Z Offline
      Zaf Khan
      wrote on last edited by
      #2

      Taking a look at the documentation.... Documentation Shows us that the Tab Control notifies the PARENT object using WM_Notify messaging. So you need to look into WM_Notfication messages. A little more can be found here Look under Notification section

      S 1 Reply Last reply
      0
      • Z Zaf Khan

        Taking a look at the documentation.... Documentation Shows us that the Tab Control notifies the PARENT object using WM_Notify messaging. So you need to look into WM_Notfication messages. A little more can be found here Look under Notification section

        S Offline
        S Offline
        steve_9496613
        wrote on last edited by
        #3

        Thank you Zaf. You gave me some useful information. I honestly do not know well how to use the WM_NOTIFY messages but looking on google I found various information about it, maybe something like this:

        Const WM_MESSAGE_TO_MANAGE As Integer = ... 'integer value of the message

        Protected Overrides Sub WndProc(ByRef m As System.Windows.Forms.Message)
        If m.Msg = WM_MESSAGE_TO_MANAGE Then
        'things to do
        End If
        MyBase.WndProc(m)
        End Sub

        In the specific situation I solved my problem in an alternative way (I don't use more different pages of the TabControl but on a single page I add N UserControl and step from one to another with buttons and I use the Click event to do what it takes) but surely this method can be useful to me on other occasions so I will look into the subject. Thank you very much.

        Z 1 Reply Last reply
        0
        • S steve_9496613

          Thank you Zaf. You gave me some useful information. I honestly do not know well how to use the WM_NOTIFY messages but looking on google I found various information about it, maybe something like this:

          Const WM_MESSAGE_TO_MANAGE As Integer = ... 'integer value of the message

          Protected Overrides Sub WndProc(ByRef m As System.Windows.Forms.Message)
          If m.Msg = WM_MESSAGE_TO_MANAGE Then
          'things to do
          End If
          MyBase.WndProc(m)
          End Sub

          In the specific situation I solved my problem in an alternative way (I don't use more different pages of the TabControl but on a single page I add N UserControl and step from one to another with buttons and I use the Click event to do what it takes) but surely this method can be useful to me on other occasions so I will look into the subject. Thank you very much.

          Z Offline
          Z Offline
          Zaf Khan
          wrote on last edited by
          #4

          Hello Steve, I came across the WM_NOTIFY message and (inter?) windows messaging in the REBAR control (ribbon/taskbar) manipulation code sample on the microsoft website which also provided me with a sample implementation that i found understandable, during the time when i was learning microsoft VB5 CCE.

          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