Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
History record while downloading a document..!!
shahbm
Hi there,
I am having a problem with Getcopy() command..
I am trying to export a document from desksite 8.2 using the GetCopy() command and it works great!!
The only problem is, it doesn't leave any history record about the document being exported. Could you pls tell me whats wrong?
here is my code,
-----------------------------------------------
Dim sDownloadpath As String
sDownloadpath = "C:\TEMP\test.doc"
Dim doc As IManDocument
Set doc = db.GetDocument(1, 1)
doc.GetCopy sDownloadpath, imNativeFormat
-----------------------------------------------
Regards,
Bhavin
Find more posts tagged with
Comments
guido1
You're using the low-level API to retrieve a copy of the document, therefore you'll need to specify the history item yourself like so:
doc.HistoryList.Add imHistoryExport, 0, 0, "MYAPPNAME"
If you want to mimick the behaviour of the client-side operations then you should look at the higher-level extensibility commands (e.g. in the iManExt library).
You could for example make use of the iManExt.ExportCmd which effectively accomplishes the same task and will automatically add the history event for you.