Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 29
Default Find tab in worksheet

I have a workbook with many tabs & many users and would like to create a 'Go
to / find' function that finds a particular tab when opening workbook, so
that user will enter tab in text box and will then go directly to tab
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,520
Default Find tab in worksheet

Try any one of these macros..

You can try out the below macro. If you are new to macros..

--Set the Security level to low/medium in (Tools|Macro|Security).
--From workbook launch VBE using short-key Alt+F11.
--From menu 'Insert' a module and paste the below code.
--Get back to Workbook.
--Run macro from Tools|Macro|Run <selected macro()


Sub Macro1()
Dim strSheet As String
strSheet = InputBox("Enter sheet name")
Sheets(strSheet).Activate
End Sub

Sub Macro2()
Dim strSheet As String
strSheet = InputBox("Enter part of sheet name")
For Each ws In Sheets
If ws.Name Like "*" & strSheet & "*" Then ws.Activate: Exit For
Next
End Sub

--
Jacob


"Rodney" wrote:

I have a workbook with many tabs & many users and would like to create a 'Go
to / find' function that finds a particular tab when opening workbook, so
that user will enter tab in text box and will then go directly to tab

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 29
Default Find tab in worksheet

Thank you v much, i have used the first one, is there any way I can make this
box appear anytime the workbook is opened ??

"Jacob Skaria" wrote:

Try any one of these macros..

You can try out the below macro. If you are new to macros..

--Set the Security level to low/medium in (Tools|Macro|Security).
--From workbook launch VBE using short-key Alt+F11.
--From menu 'Insert' a module and paste the below code.
--Get back to Workbook.
--Run macro from Tools|Macro|Run <selected macro()


Sub Macro1()
Dim strSheet As String
strSheet = InputBox("Enter sheet name")
Sheets(strSheet).Activate
End Sub

Sub Macro2()
Dim strSheet As String
strSheet = InputBox("Enter part of sheet name")
For Each ws In Sheets
If ws.Name Like "*" & strSheet & "*" Then ws.Activate: Exit For
Next
End Sub

--
Jacob


"Rodney" wrote:

I have a workbook with many tabs & many users and would like to create a 'Go
to / find' function that finds a particular tab when opening workbook, so
that user will enter tab in text box and will then go directly to tab

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,520
Default Find tab in worksheet

You can. Use the workbook open event

From workbook press Alt+F11 to launch VBE (Visual Basic Editor). From the
left treeview search for the workbook name and click on + to expand it.
Within that you should see the following

VBAProject(Your_Filename)
Microsoft Excel Objects
Sheet1(Sheet1)
Sheet2(Sheet2)
Sheet3(Sheet3)
This Workbook

Double click 'This WorkBook' and paste the below code to the right code pane.



Private Sub Workbook_Open()
'Place your code here
End Sub

--
Jacob


"Rodney" wrote:

Thank you v much, i have used the first one, is there any way I can make this
box appear anytime the workbook is opened ??

"Jacob Skaria" wrote:

Try any one of these macros..

You can try out the below macro. If you are new to macros..

--Set the Security level to low/medium in (Tools|Macro|Security).
--From workbook launch VBE using short-key Alt+F11.
--From menu 'Insert' a module and paste the below code.
--Get back to Workbook.
--Run macro from Tools|Macro|Run <selected macro()


Sub Macro1()
Dim strSheet As String
strSheet = InputBox("Enter sheet name")
Sheets(strSheet).Activate
End Sub

Sub Macro2()
Dim strSheet As String
strSheet = InputBox("Enter part of sheet name")
For Each ws In Sheets
If ws.Name Like "*" & strSheet & "*" Then ws.Activate: Exit For
Next
End Sub

--
Jacob


"Rodney" wrote:

I have a workbook with many tabs & many users and would like to create a 'Go
to / find' function that finds a particular tab when opening workbook, so
that user will enter tab in text box and will then go directly to tab

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
Can't find Column A in my worksheet Ayo Excel Discussion (Misc queries) 3 October 13th 09 10:34 PM
how to find and unlink current worksheet from old worksheet kmjmail Excel Discussion (Misc queries) 3 January 12th 09 10:52 PM
Find worksheet LantzK Excel Discussion (Misc queries) 1 May 23rd 08 05:19 PM
How do I find certain items in worksheet? dlw Excel Discussion (Misc queries) 0 March 27th 07 11:57 PM
Find Max Value in WorkSheet Corey Excel Worksheet Functions 11 January 14th 07 11:00 PM


All times are GMT +1. The time now is 12:39 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"