Friday, February 17, 2012

Exporting to Excel

Hi

I am using the DTS package with SQL SERVER 2000. I have a table, and in one
of the columns are links to websites. I am trying to export this to Excel
2002 SP3

a typical text string stored in the table is

=HYPERLINK("www.asite.com","Click")

I had hoped the field would be transferred exactly as is and so would appear
as a hyper link in the Excel document it creates. Unfortunateld it seems to
automatically put a ' in front of it so if I click on the cell, in the bar
at the top I get

'=HYPERLINK("www.asite.com","Click") - Notice the apostrophe

so the full text is displayed in the spreadsheet (rather than the word
Click)

Does anyone know of a way to get rid of the ' thats being added on

thanks in advance

AndyThat's how Excel stores text strings that begin with =. It's how it
seperates it from an expression.

"aaj" <a.b@.c.com> wrote in message news:<40a8d330$0$8090$afc38c87@.news.easynet.co.uk>...
> Hi
> I am using the DTS package with SQL SERVER 2000. I have a table, and in one
> of the columns are links to websites. I am trying to export this to Excel
> 2002 SP3
> a typical text string stored in the table is
> =HYPERLINK("www.asite.com","Click")
> I had hoped the field would be transferred exactly as is and so would appear
> as a hyper link in the Excel document it creates. Unfortunateld it seems to
> automatically put a ' in front of it so if I click on the cell, in the bar
> at the top I get
> '=HYPERLINK("www.asite.com","Click") - Notice the apostrophe
> so the full text is displayed in the spreadsheet (rather than the word
> Click)
> Does anyone know of a way to get rid of the ' thats being added on
> thanks in advance
> Andy|||>
> Does anyone know of a way to get rid of the ' thats being added on
> thanks in advance
> Andy
If you can't find a solution from by modifying the DTS package you could
write a VBA macro in the Excel document that will run when the excel
document is opened and modify the contents of a particulur column
accordingly...

No comments:

Post a Comment