rkrish - Friday, September 23, 2011 2:38 AM:
Hi,
I am trying to upload a file to Aras vault server. i can upload a file to aras vault but i can't create relationship between Document & Document Files. See below my code i highlighted in BOLD, there i am getting compile error. (The error is : Type Mismatch).
Pls any one help to solve this...
I have created VBA in Word 2007.
Regards,
RK
------------------------------------------------------------------------------------------------------------
Dim usr As Item
Set usr = innov.newItem("Document", "add")
usr.setProperty "name", ActiveDocument.name
usr.setProperty "description", ActiveDocument.FullName
' Testing to add a file Start
Dim fileItem As Item
Set fileItem = innov.newItem("File", "add")
fileItem.setFileName (ActiveDocument.FullName)
Dim relItem As Item
Set relItem = innov.newItem("Document File", "add")
usr.addRelationship (relItem)
relItem.setRelatedItem (fileItem)
' Testing to add a file End
Set usr = usr.Apply()
If (usr.IsError) Then
MsgBox result.getErrorDetail
End If
conn.Logout
aponceot - Friday, September 23, 2011 9:27 AM:
Hi,
You have to attach the file to your fileItem using attachPhysicalFile function.
Public Sub attachPhysicalFile ( _ filePath As String _ )
The 'setFileName' you use is not uploading the file into the Vault, it is just setting the name of the file.
Hope it helped.
M Rahaman - Sunday, November 24, 2013 11:29 PM:
Hi Mr.Anthony
Is there any Script /Software to upload existing Cad file to innovator server.
your help will be highly appreciated.