How to add link to the different worksheet in the same xls file?

20 views
Skip to first unread message

NikunjBadjatya

unread,
Dec 16, 2009, 12:07:08 AM12/16/09
to python-excel, saha...@gmail.com
Hi,
Is there any way i can add links to different worksheet in the same
workbook?? As we use hyperlinks to redirect us to desired webpage,
Cant we have a link to the different sheet in the same workbook??
Any advice would be greatly appreciated..!!
Thanks,

Niks
Bangalore, India

John Machin

unread,
Dec 16, 2009, 6:16:47 AM12/16/09
to python...@googlegroups.com
On 16/12/2009 4:07 PM, NikunjBadjatya wrote:
> Hi,
> Is there any way i can add links to different worksheet in the same
> workbook?? As we use hyperlinks to redirect us to desired webpage,
> Cant we have a link to the different sheet in the same workbook??

One way of getting a hyperlink is to use the HYPERLINK(Link_location,
Friendly_name) function in a formula. This can be done in any software
that supports inserting formulas in Excel worksheets (including xlwt).
Excel help says the link must be to an existing document (Excel or
Word), which may be in a filesystem or on the web).

The other way (not supported by xlwt) is to do Insert > Hyperlink in the
Excel UI. Excel help says you can link to a position in a document, and
the UI actually lets you do that, but it's not superficially obvious how
it's done. However by analogy with a URL finished off by a "#" and a
reference to a position in a web page, I tried entering #Sheet2!D7 and
it worked!

Even better, you can do this in the HYPERLINK() function, too! Enclose
it in quotes i.e. HYPERLINK("#Sheet2!D7", "Try this!")

Cheers,
John

NikunjBadjatya

unread,
Dec 17, 2009, 5:51:41 AM12/17/09
to python-excel
>
> Even better, you can do this in the HYPERLINK() function, too! Enclose
> it in quotes i.e. HYPERLINK("#Sheet2!D7", "Try this!")
>


Hey, Thanks alot for your reply..!! i successfully tried this.
working just fine..!!
Cheers
Nikunj

Reply all
Reply to author
Forward
0 new messages