Chat with a LIVE Microsoft Access Expert!
 
       
 

         

   

Go Back   Access World Forums > Microsoft Access Discussion > Forms

 
 
Chat with a LIVE Microsoft Access Expert!
Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 03-04-2010, 10:24 AM
dmr dmr is offline
Registered User
 
Join Date: Dec 2009
Posts: 30
dmr is on a distinguished road
How do I set the default tab?

I have a form with a tab control. The rightmost tab is always open when the form loads. I want the left-most tab to be open when the form loads. I can't seem to figure out how to change it.

I tried...
1) Me.TabCtl0.Value = 0
2) Me.TabCtl0.Value = 11
...in the form_load() sub. One of them should have worked!

Help!
Reply With Quote
Sponsored Links
  #2  
Old 03-04-2010, 10:26 AM
vbaInet vbaInet is offline
AWF VIP
 
Join Date: Jan 2010
Location: U.K.
Posts: 6,324
vbaInet has a spectacular aura aboutvbaInet has a spectacular aura aboutvbaInet has a spectacular aura about
Re: How do I set the default tab?

Change the Page Index property of the page. They start from 0.
Reply With Quote
  #3  
Old 03-04-2010, 10:28 AM
SOS's Avatar
SOS SOS is offline
Registered Lunatic
 
Join Date: Aug 2008
Location: Somewhere between here and there
Posts: 3,299
SOS is just really niceSOS is just really niceSOS is just really niceSOS is just really nice
Re: How do I set the default tab?

You can also just use the page name:

Me.YourTabPageName.SetFocus
Reply With Quote
  #4  
Old 03-04-2010, 10:38 AM
dmr dmr is offline
Registered User
 
Join Date: Dec 2009
Posts: 30
dmr is on a distinguished road
Re: How do I set the default tab?

Quote:
Originally Posted by vbaInet View Post
Change the Page Index property of the page. They start from 0.
How can I do that?
Reply With Quote
  #5  
Old 03-04-2010, 10:39 AM
dmr dmr is offline
Registered User
 
Join Date: Dec 2009
Posts: 30
dmr is on a distinguished road
Re: How do I set the default tab?

Quote:
Originally Posted by SOS View Post
You can also just use the page name:

Me.YourTabPageName.SetFocus
Thank you! This worked!
Reply With Quote
  #6  
Old 03-04-2010, 10:51 AM
vbaInet vbaInet is offline
AWF VIP
 
Join Date: Jan 2010
Location: U.K.
Posts: 6,324
vbaInet has a spectacular aura aboutvbaInet has a spectacular aura aboutvbaInet has a spectacular aura about
Re: How do I set the default tab?

Quote:
Originally Posted by dmr View Post
How can I do that?
Just FYI, right click the tab and click Page Order then move things up or down as you wish. You can also set it via the Properties Sheet on the Format tab by clicking on the Page you wish to make the first and set it to 0.

Glad SOS' solution worked for you.
Reply With Quote
Sponsored Links
Reply

Tags
default, tab control

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Outlook calendar (Delete and update) robyholmes Modules & VBA 20 02-01-2010 12:19 AM
Formatting Pivot Chart via VB code sphynx Modules & VBA 0 11-21-2007 07:01 AM
Set Default of Field from Another Table's Field Entry SaraRob Tables 0 06-12-2006 03:39 PM
Query to fill in blanks within a table? Maybe some other way? robjones23 Queries 11 03-21-2005 02:10 AM


All times are GMT -8. The time now is 09:40 AM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
(c) copyright 2009 Access World