Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
On Thursday, July 5, 2012 5:23:39 AM UTC-5, Chulius Caesar wrote:
I have a sheet which uses query table to download several different tables of stock data onto a temporary sheet "Raw Data" based on input stock code on main "sheet1". Basically I need a code to create a new sheet with the name of the stock code from "sheet1". However, I want it to search through all the existing sheets, and if that sheet exists already (i.e has been searched previously) then I want that to become the active sheet. I will then append the data to the end of existing data on that sheet. -- Chulius Caesar You can use something like this. If desired send your file to ME. Dim WantedSheet As String WantedSheet = Trim(ActiveCell.Value) If WantedSheet = "" Then Exit Sub On Error Resume Next If Sheets(ActiveCell.Value) Is Nothing Then MsgBox "Worksheet " & WantedSheet & " was not found, use RClick on " _ & "Sheet Tab Navigation arrow in lower left corner " _ & "to find desired sheetname." Else Sheets(ActiveCell.Value).Select End If |
#2
![]() |
|||
|
|||
![]() Quote:
|
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Create New Sheets and Name Them Based on Values in another sheet | Excel Discussion (Misc queries) | |||
create sheet based on value in string | Excel Programming | |||
Create new sheets based off Data sheet, and template sheet | Excel Programming | |||
Create Cell Comment based on text in a cell on another worksheet | Excel Discussion (Misc queries) | |||
Create summary based on specifc value in a different sheet | Excel Worksheet Functions |