+ Reply to Thread
Results 1 to 4 of 4

Sequential Method to Set Focusing of Text Boxes

  1. #1
    Forum Contributor
    Join Date
    01-07-2012
    Location
    Bangalore
    MS-Off Ver
    Office 365
    Posts
    368

    Sequential Method to Set Focusing of Text Boxes

    Dear Experts,

    It may be very simple task, but l am unable incorporate with my code.

    Need your support on the same. I have built a Userform which contains below listed Text & Combo Boxes in it!

    Label Name: Boxes Name: Updation Method: -

    Label 1 Date_ (Text Box) Auto Update
    Label15 Data_Entry (Text Box) Auto Update
    Label2 Page_No (Text Box) Manual Update
    Label5 Zone (Text Box) Manual Update
    Label3 PartNumber (Combo Box) Manual Update
    Label4 Description Auto Update
    Label6 Category (Combo Box) Manual Update
    Label7 C_LL (Text Box) Manual Update
    Label8 Colour Manual Update
    Label11 UOM_CC Manual Update
    Label13 UOM_MM Auto Update
    Label14 UOM_Check Auto Update
    Label9 Qty Manual Update
    Label10 F_Qty Auto Update

    Below is the code which is been built and it is working very much find. However, since I am new VBA, I am unable to incorporate “SetFocus” Sequence as per my Need!

    Focusing appropriate cell is mandatory because it is used by multiple users!

    Please help me to add code along with below codes to meet following set focus sequence:-

    By Default, when “userform” Initialize it keeps setfocus to “Page No” .

    1. After updation of “Page No”, cursor has to focus on “Zone”
    2. After Update cursor has to focus on “PartNumber”
    3. After Update cursor has to focus on “Category”
    4. After Update cursor has to focus on “UOM_CC”
    5. After Update Cursor has to focus on “Qty”

    Looking forward your valuable input!

    Please Login or Register  to view this content.
    Thanks & Regards,
    Rajeshkumar R
    Last edited by Rajeshkumar R; 10-22-2017 at 01:11 AM. Reason: Query Resolved

  2. #2
    Forum Expert
    Join Date
    11-22-2016
    Location
    Cornwall,UK
    MS-Off Ver
    office 365
    Posts
    4,240

    Re: Sequential Method to Set Focusing of Text Boxes

    I use the Change_Event with a suitable condition to verify the imput in each box - here are a few examples
    If user forced to select value from list (combobox) then selection triggers focus set to next box
    see attached workbook

    Please Login or Register  to view this content.
    Attached Files Attached Files
    Last edited by kev_; 10-21-2017 at 04:15 AM.
    Click *Add Reputation to thank those who helped you. Ask if anything is not clear

  3. #3
    Forum Guru bakerman2's Avatar
    Join Date
    10-03-2012
    Location
    Antwerp, Belgium
    MS-Off Ver
    MO Prof Plus 2016
    Posts
    6,908

    Re: Sequential Method to Set Focusing of Text Boxes

    Why not just set the TabIndex of your objects in the wright order starting from 0 for Page No, 1 for Zone, ....
    Avoid using Select, Selection and Activate in your code. Use With ... End With instead.
    You can show your appreciation for those that have helped you by clicking the * at the bottom left of any of their posts.

  4. #4
    Forum Contributor
    Join Date
    01-07-2012
    Location
    Bangalore
    MS-Off Ver
    Office 365
    Posts
    368

    Re: Sequential Method to Set Focusing of Text Boxes

    Dear kev_,

    Thanks for your suggestion, I could able to incorporate in my code!

    Regards,
    Rajeshkumar R

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Dear friends I am focusing on vb coding in Excel sheets
    By ROY_Z in forum Hello..Introduce yourself
    Replies: 3
    Last Post: 12-15-2016, 09:22 PM
  2. Using List boxes and text boxes with complex data sets
    By Mlanger575 in forum Excel Programming / VBA / Macros
    Replies: 25
    Last Post: 11-06-2016, 01:11 PM
  3. Lossing Chart Boxes/ Text boxes when close file
    By david2003 in forum Excel Charting & Pivots
    Replies: 0
    Last Post: 11-05-2014, 09:39 AM
  4. [SOLVED] Text Boxes: Insert/Text Box vs. Developer Text Boxes
    By snapfade in forum Excel General
    Replies: 5
    Last Post: 10-09-2012, 01:45 AM
  5. single group of code to reference multiple sequential names of active x check boxes
    By ferrum_equitis in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-01-2012, 03:25 AM
  6. Replies: 2
    Last Post: 02-19-2010, 03:55 PM
  7. Focusing on open workbooks
    By matpj in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-02-2005, 10:13 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1