• 0

word document with asp


Question

hi all,

I am opening a .asp page in .doc (word) format on client side and give an

option to the client to save it on disk.

My .asp page have some information and 2 images.

I have tried with the following code:

code :

Response.ContentType = "application/vnd.ms-word"

Response.AddHeader "Content-Disposition","attachment; filename=Abc.doc"

What happened when i run the code:

When i run the page, i got a File save dialog box and i am able to save

the file on client side.

BUT in the .doc file saved on client side, can not save images and only empty box can be seen in the word document.

If any one of you have a sample code to make the images appear in the word document would be helpful to me.

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

  • 0

Does your word document actually embed the image or does it link to an image? For example, if you embedded a 4MB bitmap, your document file size would increase by 4MB. However if you linked to a 4MB bitmap, your document file size would be the same. If you link your images, the client on the other side wouldn't be able to see the image because the link in your document is no longer valid. But if you embedded your images, then the image would be copied into your document and the client would be able to see them.

That's the only thing I can think of that would be causing your problem.

Link to comment
Share on other sites

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.