G
Guest
I am using Microsoft's dsofile (http://support.microsoft.com/support/kb/articles/Q224/3/51.asp) in an ASP to update a set of custom properties in a Word document. The document
properties are always correctly updated after running the script on the ASP. However, after running the ASP for the second or third time IIS will lock and will fail to respond to any request until I restart IIS or get some error (note that the error is not always the same, it can be "internal error"; "trappable error"; "IIS catastrophic failure"; "ASP timeout", ...). I get this behavior on both IIS 5.1 (XP Pro) and IIS 6.0 (2003 Server).
Here is what I am doing on the ASP:
filename = "PATH TO SOME WORD FILE"
set oFilePropReader = CreateObject("DSOleFile.PropertyReader")
oFilePropReader.UseUnicodePropSets = true
set oDocProp = oFilePropReader.GetDocumentProperties(filename)
if not oDocProp.IsReadOnly then
oDocProp.CustomProperties.Item("SOME_PROPERTY").Value = "something"
end if
set oDocProp = Nothing
set oFilePropReader = Nothing
Please note that even when IIS fails the document properties are always updated, so I guess the problem is not a dsofile internal problem but some problem related to creating/deleting the DSOleFile object on IIS. I have already tried to create the object on global.asa on application start, session start and as an <object>, but IIS continues to lock up after 2 or 3 runs of this page.
Any suggestions from what may be causing this problem?
Thanks, Artur
**********************************************************************
Sent via Fuzzy Software @ http://www.fuzzysoftware.com/
Comprehensive, categorised, searchable collection of links to ASP & ASP.NET resources...
properties are always correctly updated after running the script on the ASP. However, after running the ASP for the second or third time IIS will lock and will fail to respond to any request until I restart IIS or get some error (note that the error is not always the same, it can be "internal error"; "trappable error"; "IIS catastrophic failure"; "ASP timeout", ...). I get this behavior on both IIS 5.1 (XP Pro) and IIS 6.0 (2003 Server).
Here is what I am doing on the ASP:
filename = "PATH TO SOME WORD FILE"
set oFilePropReader = CreateObject("DSOleFile.PropertyReader")
oFilePropReader.UseUnicodePropSets = true
set oDocProp = oFilePropReader.GetDocumentProperties(filename)
if not oDocProp.IsReadOnly then
oDocProp.CustomProperties.Item("SOME_PROPERTY").Value = "something"
end if
set oDocProp = Nothing
set oFilePropReader = Nothing
Please note that even when IIS fails the document properties are always updated, so I guess the problem is not a dsofile internal problem but some problem related to creating/deleting the DSOleFile object on IIS. I have already tried to create the object on global.asa on application start, session start and as an <object>, but IIS continues to lock up after 2 or 3 runs of this page.
Any suggestions from what may be causing this problem?
Thanks, Artur
**********************************************************************
Sent via Fuzzy Software @ http://www.fuzzysoftware.com/
Comprehensive, categorised, searchable collection of links to ASP & ASP.NET resources...