Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Save HTML to Word Document

Posted on 2000-05-12
1
Medium Priority
?
1,411 Views
Last Modified: 2008-03-03
Dear Experts,

I have created some letters for the users and the content are put into textareas and tables, after that they are edited by the users, then the content are outputted as HTML format.

Now I want to save this "HTML" into a word document, how can I do that?

I have tried the method posted previously by others but it didn't work

' Get the IIsWebService Admin object
'Set oWebService = GetObject("IIS://LocalHost/W3svc")

' Enable AspAllowOutOfProcComponents
'oWebService.Put "AspAllowOutOfProcComponents", True

' Save the changed value to the metabase
'oWebService.SetInfo

'set oWD = Server.CreateObject "Word.Application")
'oWD.Documents.Add
'oWD.selection.typetext "Hello, World!"
'oWD.ActiveDocument.SaveAs "C:\Temp\Hello.doc"
'oWD.ActiveDocument.Close
'oWD.Quit
'set oWD = Nothing


I got the error :
Permission denied: 'GetObject'
when I execute
Set oWebService = GetObject ("IIS://LocalHost/W3svc")

can anyone tell me why?
thx
0
Comment
Question by:edwardpoon
1 Comment
 

Accepted Solution

by:
CoreEye earned 200 total points
ID: 2806893
Hi,
 because if you are connecting the web site with anonymous account this error occurs. First give the site NT Authentication to connect then try it again. To do this in IIS manager select your site and click properties, at the "Directory Security" tab click "edit" and select "NT Challenge/Reponse".

And also it is enough to run this code once;

Set oWebService = GetObject("IIS://LocalHost/W3svc")

 Enable AspAllowOutOfProcComponents
oWebService.Put "AspAllowOutOfProcComponents", True

'oWebService.SetInfo

i guess you to execute this code in a seperate page once, then change your sites security settings to old state.
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I would like to start this tip/trick by saying Thank You, to all who said that this could not be done, as it forced me to make sure that it could be accomplished. :) To start, I want to make sure everyone understands the importance of utilizing p…
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an anti-spam), the admin…
Look below the covers at a subform control , and the form that is inside it. Explore properties and see how easy it is to aggregate, get statistics, and synchronize results for your data. A Microsoft Access subform is used to show relevant calcul…
Suggested Courses

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question