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. C#
  4. tab page questions

tab page questions

Scheduled Pinned Locked Moved C#
questiondatabasehelptutorial
4 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.
  • R Offline
    R Offline
    rzvme
    wrote on last edited by
    #1

    I have afew questions regarding the tab page control: 1) I have to force the user to not change the page untill a database is loaded. I used the invalidating event to force the user not to change focus untill the dataset is loaded. the only problem is: i don't kow how to put the condition: dataset.tables.count!=0 is right?? and does the validating event actually worg between tab pages? 2) I want certain tab pages to be either disabled (I mean to appear on the tab control disabled, not all the controls on it to be disabled) or invisible(likevise) how do i do that?

    rzvme

    N L 2 Replies Last reply
    0
    • R rzvme

      I have afew questions regarding the tab page control: 1) I have to force the user to not change the page untill a database is loaded. I used the invalidating event to force the user not to change focus untill the dataset is loaded. the only problem is: i don't kow how to put the condition: dataset.tables.count!=0 is right?? and does the validating event actually worg between tab pages? 2) I want certain tab pages to be either disabled (I mean to appear on the tab control disabled, not all the controls on it to be disabled) or invisible(likevise) how do i do that?

      rzvme

      N Offline
      N Offline
      Nader Elshehabi
      wrote on last edited by
      #2

      rzvme wrote:

      i don't kow how to put the conditio

      1)If you use .Net 2.0 there is an event called DataSet.Initialized, and a property called DataSet.IsInitialized. When the Dataset finishes initialization, the event fires, and the property is set to true.

      rzvme wrote:

      1. I want certain tab pages to be either disabled (I mean to appear on the tab control disabled, not all the controls on it to be disabled) or invisible(likevise) how do i do that?
      1. I don't think I caught up with you, but if I got you right, then you don't want to hide, nor disable the tabpages and the inner controls, yet you still don't want to allow changing the current page. You can handle TabControl.SelectedIndexChanged event, and check IsInitialized in it. If it wasn't true, revert the selected index to the page you desire.

      Regards:rose:

      1 Reply Last reply
      0
      • R rzvme

        I have afew questions regarding the tab page control: 1) I have to force the user to not change the page untill a database is loaded. I used the invalidating event to force the user not to change focus untill the dataset is loaded. the only problem is: i don't kow how to put the condition: dataset.tables.count!=0 is right?? and does the validating event actually worg between tab pages? 2) I want certain tab pages to be either disabled (I mean to appear on the tab control disabled, not all the controls on it to be disabled) or invisible(likevise) how do i do that?

        rzvme

        L Offline
        L Offline
        lainoo
        wrote on last edited by
        #3
        1. you may write :dataset.tables[tablename].Rows.count!=0 2) tabpagechange event can handle this.

        Sorry ...

        R 1 Reply Last reply
        0
        • L lainoo
          1. you may write :dataset.tables[tablename].Rows.count!=0 2) tabpagechange event can handle this.

          Sorry ...

          R Offline
          R Offline
          rzvme
          wrote on last edited by
          #4

          yes, but how do i get the page(index or name) from wich the index/name was chaged? the tab control doesn't have a last selected page or last selected index property. Another problem is the fact, i think, the tabcontrol selected index changed occurs after the tabpageenter event. -- modified at 1:48 Sunday 29th October, 2006

          rzvme

          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