ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Setting Tab Index for Text Fields (https://www.excelbanter.com/excel-programming/347588-re-setting-tab-index-text-fields.html)

Vamshi Krishna

Setting Tab Index for Text Fields
 
Thank You for the response Jim,

I understand I cannot move the cursor in between textboxes, I tried
creating a Userform looks like a VBE form in Excel, by then when I close the
Excel sheet and Open it again I am not able to view the Userform, I can only
view the sheet, to view the Userform I need to go to VisualBasic ToolBar and
Click on Design. My aim is to save the Excel sheet as a Template where
others can use this DataEntry form to enter data, however If I am not able to
view the UserForm when I open this Template then I Cannot help my People,
Please provide me a Solution.

Thank You,

"Jim Rech" wrote:

It is not possible to set focus to a control on a worksheet. Users will
have to click the control they want to use. If you require that kind of
functionality you'd have to create your form on a user form in the VBE.
Userforms are quite similar to the forms you're used to in standalone VB.

When I design 'forms' on a worksheet I use the cells for typed input as much
as possible so that tabbing between input cells is possible.

--
Jim
"Vamshi Krishna" <Vamshi wrote in message
...
| Hi,
| I am designing a Data Entry kind of a form where I put Textboxes,
| Comboboxes, etc., in Excel2003 sheet, I am almost finished with the
| programming and validations, however I am facing a problem in moving the
| cursor from one textbox to another, In Visual basic we have a property
called
| "TabIndex" for a Textbox, however I cannot see a "Tabindex" property for a
| Textbox and there is no method called "SetFocus" for a textbox. Please
help
| me in completing my DataEntry form.
|
| Thanks in Advance.
|




Jim Rech

Setting Tab Index for Text Fields
 
You do have to write some code to open the userform it is true. But the
code is extremely simple:

Sub ShowForm()
Userform1.Show
End Sub

You could attach this to a button on the worksheet so the user can click it
to open the form. Also you could call this macro from the workbook open
event handler (Sub Workbook_Open) in the ThisWorkbook module to have it
called automatically when the workbook is opened. Naturally the user has to
enable macros for any of this to work.

--
Jim
"Vamshi Krishna" wrote in message
...
| Thank You for the response Jim,
|
| I understand I cannot move the cursor in between textboxes, I tried
| creating a Userform looks like a VBE form in Excel, by then when I close
the
| Excel sheet and Open it again I am not able to view the Userform, I can
only
| view the sheet, to view the Userform I need to go to VisualBasic ToolBar
and
| Click on Design. My aim is to save the Excel sheet as a Template where
| others can use this DataEntry form to enter data, however If I am not able
to
| view the UserForm when I open this Template then I Cannot help my People,
| Please provide me a Solution.
|
| Thank You,
|
| "Jim Rech" wrote:
|
| It is not possible to set focus to a control on a worksheet. Users will
| have to click the control they want to use. If you require that kind of
| functionality you'd have to create your form on a user form in the VBE.
| Userforms are quite similar to the forms you're used to in standalone
VB.
|
| When I design 'forms' on a worksheet I use the cells for typed input as
much
| as possible so that tabbing between input cells is possible.
|
| --
| Jim
| "Vamshi Krishna" <Vamshi wrote in
message
| ...
| | Hi,
| | I am designing a Data Entry kind of a form where I put Textboxes,
| | Comboboxes, etc., in Excel2003 sheet, I am almost finished with the
| | programming and validations, however I am facing a problem in moving
the
| | cursor from one textbox to another, In Visual basic we have a property
| called
| | "TabIndex" for a Textbox, however I cannot see a "Tabindex" property
for a
| | Textbox and there is no method called "SetFocus" for a textbox.
Please
| help
| | me in completing my DataEntry form.
| |
| | Thanks in Advance.
| |
|
|
|




All times are GMT +1. The time now is 05:37 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com