Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
JGI JGI is offline
external usenet poster
 
Posts: 3
Default How do I tabulate between textbox controls in EXCEL?

In pure Visual Basic it is possible to use the tab key to
pass between textbox controls, however I have not found a
way of doing this in Excel's Visual Basic editor. Any
ideas would be welcome. Thank you.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default How do I tabulate between textbox controls in EXCEL?

Is this on a userform. If so, there is a TabIndex property that allows you
to set the tab order.

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"JGI" wrote in message
...
In pure Visual Basic it is possible to use the tab key to
pass between textbox controls, however I have not found a
way of doing this in Excel's Visual Basic editor. Any
ideas would be welcome. Thank you.



  #3   Report Post  
Posted to microsoft.public.excel.programming
JGI JGI is offline
external usenet poster
 
Posts: 3
Default How do I tabulate between textbox controls in EXCEL?

These are textbox controls placed directly onto an Excel 97 worksheet. They have no TabIndex property !

----- Bob Phillips wrote: -----

Is this on a userform. If so, there is a TabIndex property that allows you
to set the tab order.

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"JGI" wrote in message
...
In pure Visual Basic it is possible to use the tab key to
pass between textbox controls, however I have not found a
way of doing this in Excel's Visual Basic editor. Any
ideas would be welcome. Thank you.




  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default How do I tabulate between textbox controls in EXCEL?

If they are control toolbox controls, this code will work for them.

Private Sub TextBox1_KeyDown(ByVal KeyCode As MSForms.ReturnInteger, _
ByVal Shift As Integer)
Dim bBackwards As Boolean

Select Case KeyCode
''' These are the only keys we care about.
Case vbKeyTab, vbKeyReturn, vbKeyDown, vbKeyUp
Application.ScreenUpdating = False
''' Determine if we need to move backwards.
bBackwards = CBool(Shift And 1) Or (KeyCode = vbKeyUp)
''' In Excel 97 must select cell before activating another
control.
If Application.Version < 9 Then Sheet1.Range("A1").Select
''' Activate the appropriate control based on key(s) pressed.
If bBackwards Then
TextBox3.Activate
Else
TextBox2.Activate
End If
Application.ScreenUpdating = True
End Select
End Sub


add similar code for each control.

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"JGI" wrote in message
...
These are textbox controls placed directly onto an Excel 97 worksheet.

They have no TabIndex property !

----- Bob Phillips wrote: -----

Is this on a userform. If so, there is a TabIndex property that

allows you
to set the tab order.

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"JGI" wrote in message
...
In pure Visual Basic it is possible to use the tab key to
pass between textbox controls, however I have not found a
way of doing this in Excel's Visual Basic editor. Any
ideas would be welcome. Thank you.






  #5   Report Post  
Posted to microsoft.public.excel.programming
JGI JGI is offline
external usenet poster
 
Posts: 3
Default How do I tabulate between textbox controls in EXCEL?

Thank you for your help.


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem with TAB key and Textbox controls Paul M[_4_] Excel Programming 2 June 6th 14 05:54 PM
how do I tabulate data in excel 2003 Becky Excel Discussion (Misc queries) 2 May 14th 10 12:03 AM
how can I use excel to tabulate survey results Maiadd Excel Worksheet Functions 2 August 3rd 06 11:29 PM
how can I use excel to tabulate survey results Maiadd Excel Worksheet Functions 1 August 1st 06 07:50 PM
how do I tabulate written information in excel? excel Charts and Charting in Excel 1 August 22nd 05 02:25 PM


All times are GMT +1. The time now is 11:27 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"