export gif Excel

L

Lilia

Hello

I need to export picture(gif) created with ChartSpace(OWC), TO EXCEL.

I have code for export data to Excel:
ImagePath=server.mappath("PricesExport.gif")
oChart.ExportPicture ImagePath, "gif",600,500
Response.Write("<IMG SRC='PricesExport.gif'>")

Response.ContentType ="Application/vnd.excel"
Response.AddHeader "Content-Disposition", "attachment;
filename=PreciosMPS.xls"

but, it doesn't show the Chart (GIF)

I'm using ASP code

Thank you for your help
 
A

Alvin Bruney [MVP]

you will most likely need to use a more appropriate content type since what
you are using is excel but exporting a picture image
 
L

Lilia

some code idea?

I don't know as beginning



Alvin Bruney said:
you will most likely need to use a more appropriate content type since what
you are using is excel but exporting a picture image

--
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
Lilia said:
Hello

I need to export picture(gif) created with ChartSpace(OWC), TO EXCEL.

I have code for export data to Excel:
ImagePath=server.mappath("PricesExport.gif")
oChart.ExportPicture ImagePath, "gif",600,500
Response.Write("<IMG SRC='PricesExport.gif'>")

Response.ContentType ="Application/vnd.excel"
Response.AddHeader "Content-Disposition", "attachment;
filename=PreciosMPS.xls"

but, it doesn't show the Chart (GIF)

I'm using ASP code

Thank you for your help
 
A

Alvin Bruney [MVP]

no, no code just change the content type. I used to have a complete listing
of all available content types but i no longer can find it. you will have to
google around.
Response.ContentType ="Application/vnd.excel"
this is the line you will need to change to the appropriate type because
this current one is expecting .xls format
--
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
Lilia said:
some code idea?

I don't know as beginning



Alvin Bruney said:
you will most likely need to use a more appropriate content type since
what
you are using is excel but exporting a picture image

--
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
Lilia said:
Hello

I need to export picture(gif) created with ChartSpace(OWC), TO EXCEL.

I have code for export data to Excel:
ImagePath=server.mappath("PricesExport.gif")
oChart.ExportPicture ImagePath, "gif",600,500
Response.Write("<IMG SRC='PricesExport.gif'>")

Response.ContentType ="Application/vnd.excel"
Response.AddHeader "Content-Disposition", "attachment;
filename=PreciosMPS.xls"

but, it doesn't show the Chart (GIF)

I'm using ASP code

Thank you for your help
 
L

Lilia

I could have two CONTENT TYPE?
because, I need send to excel DATA AND IMAGES
Thank you for your time.

Alvin Bruney said:
no, no code just change the content type. I used to have a complete listing
of all available content types but i no longer can find it. you will have to
google around.
Response.ContentType ="Application/vnd.excel"
this is the line you will need to change to the appropriate type because
this current one is expecting .xls format
--
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
Lilia said:
some code idea?

I don't know as beginning



Alvin Bruney said:
you will most likely need to use a more appropriate content type since
what
you are using is excel but exporting a picture image

--
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
Hello

I need to export picture(gif) created with ChartSpace(OWC), TO EXCEL.

I have code for export data to Excel:
ImagePath=server.mappath("PricesExport.gif")
oChart.ExportPicture ImagePath, "gif",600,500
Response.Write("<IMG SRC='PricesExport.gif'>")

Response.ContentType ="Application/vnd.excel"
Response.AddHeader "Content-Disposition", "attachment;
filename=PreciosMPS.xls"

but, it doesn't show the Chart (GIF)

I'm using ASP code

Thank you for your help
 
L

Lilia

I could have two CONTENT TYPE?
because, I need send to excel DATA AND IMAGES
Thank you for your time.



Alvin Bruney said:
no, no code just change the content type. I used to have a complete listing
of all available content types but i no longer can find it. you will have to
google around.
Response.ContentType ="Application/vnd.excel"
this is the line you will need to change to the appropriate type because
this current one is expecting .xls format
--
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
Lilia said:
some code idea?

I don't know as beginning



Alvin Bruney said:
you will most likely need to use a more appropriate content type since
what
you are using is excel but exporting a picture image

--
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
Hello

I need to export picture(gif) created with ChartSpace(OWC), TO EXCEL.

I have code for export data to Excel:
ImagePath=server.mappath("PricesExport.gif")
oChart.ExportPicture ImagePath, "gif",600,500
Response.Write("<IMG SRC='PricesExport.gif'>")

Response.ContentType ="Application/vnd.excel"
Response.AddHeader "Content-Disposition", "attachment;
filename=PreciosMPS.xls"

but, it doesn't show the Chart (GIF)

I'm using ASP code

Thank you for your help
 
A

Alvin Bruney [MVP]

nope you can only have one. content type sets the type of content for the
entire page

--
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
Lilia said:
I could have two CONTENT TYPE?
because, I need send to excel DATA AND IMAGES
Thank you for your time.



Alvin Bruney said:
no, no code just change the content type. I used to have a complete
listing
of all available content types but i no longer can find it. you will have
to
google around.
Response.ContentType ="Application/vnd.excel"
this is the line you will need to change to the appropriate type because
this current one is expecting .xls format
--
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
Lilia said:
some code idea?

I don't know as beginning



:

you will most likely need to use a more appropriate content type since
what
you are using is excel but exporting a picture image

--
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
Hello

I need to export picture(gif) created with ChartSpace(OWC), TO
EXCEL.

I have code for export data to Excel:
ImagePath=server.mappath("PricesExport.gif")
oChart.ExportPicture ImagePath, "gif",600,500
Response.Write("<IMG SRC='PricesExport.gif'>")

Response.ContentType ="Application/vnd.excel"
Response.AddHeader "Content-Disposition", "attachment;
filename=PreciosMPS.xls"

but, it doesn't show the Chart (GIF)

I'm using ASP code

Thank you for your help
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top