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 wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Response.ContentType="application/msword"

Status
Not open for further replies.

nazzaro

Programmer
Jun 28, 2000
31
US
Has anyone had experience using:

<% ResponseContentType=&quot;application/msword&quot; %>

to send msword content from asp pages?

I'm trying to figure out a way to &quot;send&quot; the proper document template (.dot file) so it gets attached to the document opened in Word by the client.

So far, it seems that the HREF for

<w:AttachedTemplate HRef=&quot;location of template goes here&quot;></w:AttachedTemplate>

(xml stuff as child to w:WordDocument) cannot be a web address.

(btw, I've been able to specify web addresses for other items like the header.htm file for headers, footnote separator, footnote continuation separators, etc. in the style section and also for images - .png and .gif - used in the document in the v: xml namespace)

Any thoughts?
 
> <% ResponseContentType=&quot;application/msword&quot; %>

First it would have to be:

Response.ContentType = ....

Then you are telling the browser that the content of the reply is the bytes of an msword document. Is that what you are sending?

-pete
 
You're right (subject has correct syntax, but I messed it up in the body.

Yes, the document is sent correctly and opens in MsWord, but does not reference the template specified in:

<w:AttachedTemplate HRef=&quot;location of template goes here&quot;></w:AttachedTemplate>

 
nazzaro,

<w:AttachedTemplate HRef=&quot;location of template goes here&quot;></w:AttachedTemplate>

I am total lost at this point. Do you have a reference to documentation that you used to devise the technique you are attempting?

-pete
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top