Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

calling an excel bookmark within a URL

Status
Not open for further replies.

jefflatkidsii

Programmer
Sep 21, 2006
3
0
0
US
I have an excel spreadsheet on a website, and I want to create a URL that will open up a particular sheet within the file.

I can easily do this when creating a bookmark hyperlink within a spreadsheet, and the link looks like, file:///\\k2server\web\Excel\YearlyReports.xls#'2006 Reports'!A1.

However, when I try to pass this same parameter through a URL the file opens but it ignores the bookmark that I'm trying to call. The URL i'm using is Reports'!A1.

Basically, I'd like to know if there's a way to configure the parameters within a URL to be able to open a specific sheet within an excel file, or can this only be accomplished within excel?

any help on this would be much appreciated!

thx,
Jeff
 
You can put an autorun macro into the workbook to automatically go where you want when it opens. Then the link will open the file, and the macro will select the correct cell or sheet as soon as it is opened. It might look like this:

Sub Auto_Open()

Sheets("Sheet2").Select
Range("D11").Select

End Sub

That would select sheet2, and go directly to cell D11.

Sawedoff

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top