473,508 Members | 2,274 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Event When Tab is Selected

I am using VB in VS.NET 2003 and my startup form has a tab control with 8
different tabs. If the user selects a specific tab I want to populate some
combo boxes and text fields on that tab. I am thinking that it is not wise
to populate every control on every tab at form_load time?

What is the best way to approach this?

TIA

Wayne
Nov 20 '05 #1
2 1375
* "Wayne Wengert" <wa***************@wengert.com> scripsit:
I am using VB in VS.NET 2003 and my startup form has a tab control with 8
different tabs. If the user selects a specific tab I want to populate some
combo boxes and text fields on that tab. I am thinking that it is not wise
to populate every control on every tab at form_load time?


Add a handler to the tabcontrol's 'SelectedIndexChanged' event and check
the control's 'SelectedTab' or 'SelectedIndex' property there.

--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/>
Nov 20 '05 #2
Thanks... I'll give that a try.

Wayne

"Herfried K. Wagner [MVP]" <hi***************@gmx.at> wrote in message
news:2k*************@uni-berlin.de...
* "Wayne Wengert" <wa***************@wengert.com> scripsit:
I am using VB in VS.NET 2003 and my startup form has a tab control with 8 different tabs. If the user selects a specific tab I want to populate some combo boxes and text fields on that tab. I am thinking that it is not wise to populate every control on every tab at form_load time?


Add a handler to the tabcontrol's 'SelectedIndexChanged' event and check
the control's 'SelectedTab' or 'SelectedIndex' property there.

--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/>

Nov 20 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
3141
by: Emerson | last post by:
The following assumes a System.Windows.Forms.DataGrid with a System.Data.DataTable set as the DataSource. I'm programming in C# Here's my scenario I click in a cell on a DataGrid. I enter some...
8
4297
by: Donald Xie | last post by:
Hi, I noticed an interesting effect when working with controls that are dynamically loaded. For instance, on a web form with a PlaceHolder control named ImageHolder, I dynamically add an image...
5
3354
by: tshad | last post by:
Is there a way to allow a user to press a radio button if it is already selected? There is an onCheckedChanged event that fires when the person presses the button and it is isn't selected...
1
2677
by: e | last post by:
I have an ownerdrawn listbox that paints items in various colors dependant upon whether or not it has focus, selected, etc. The code that physically paints the items is in the drawItem event, and...
10
1864
by: HABJAN ®iga | last post by:
Ok, the trouble: On form: Mask (lots of textboxes & ...) Listview 1 as Listview with some items booEdit as boolean=False intEditIndex as integer Scenario:
4
9372
by: Andrew Robinson | last post by:
I am using a TreeView to perform navigation and have a few nodes that need to generate a popup menu. For this, I use the SelectedNodeChanged event and then add the relevant "window.open" script to...
5
13937
by: Stuart Shay | last post by:
Hello All I am working on ASP.NET 1.1 Custom Pager that allows a User to Enter a Number in a TextBox and go to the page selected. Since the OnClick Event does not work in ASP.NET 1.1 for a...
1
1094
by: msch-prv | last post by:
I would like to raise the selected event of an objectdatasource (ods) to retrieve some data. I tried to raise this event using a server button. I am at a loss as to how set up the RaiseEvent syntax...
12
3996
by: Tom Bean | last post by:
I am trying to display a ContextMenuStrip when a user right-clicks on an item in a ListView and have encountered a something that seems strange to me. When the ListView is initially populated,...
0
7229
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7129
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7333
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7398
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
7061
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7502
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
1
5057
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
3194
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1566
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.