Preview | SOLIDWORKS USER FORUM
Use your SOLIDWORKS ID or 3DEXPERIENCE ID to log in.
szsha zhehua16/09/2008
I am using the SwDocumentMgr 2007 type Library.
My license key is apisupport assigned.
When run the following code , the error can see.
Dim swDocMgr As SwDocumentMgr.SwDMApplication
Dim swDoc As SwDocumentMgr.SwDMDocument
Dim classfac As SwDocumentMgr.SwDMClassFactory
Set classfac = CreateObject("SwDocumentMgr.SwDMClassFactory")
Set swDocMgr = classfac.GetApplication("license key") 'Specify your license key
Set swDoc = swDocMgr.GetDocument("E:\1.SLDPRT", swDmDocumentPart, True, swDmDocumentOpenErrorNone)
Debug.Print "param string:" & swDoc.GetCustomProperty("name", swDmCustomInfoText)
swDoc.CloseDoc
Set swDoc = Nothing
Set swDocMgr = Nothing
Set classfac = Nothing
End Sub
Set swDocMgr = classfac.GetApplication("license key") 'Specify your license key
Error: ActiveX can't create the object.
What about it ?
License key is wrong ?
My license key is apisupport assigned.
When run the following code , the error can see.
Dim swDocMgr As SwDocumentMgr.SwDMApplication
Dim swDoc As SwDocumentMgr.SwDMDocument
Dim classfac As SwDocumentMgr.SwDMClassFactory
Set classfac = CreateObject("SwDocumentMgr.SwDMClassFactory")
Set swDocMgr = classfac.GetApplication("license key") 'Specify your license key
Set swDoc = swDocMgr.GetDocument("E:\1.SLDPRT", swDmDocumentPart, True, swDmDocumentOpenErrorNone)
Debug.Print "param string:" & swDoc.GetCustomProperty("name", swDmCustomInfoText)
swDoc.CloseDoc
Set swDoc = Nothing
Set swDocMgr = Nothing
Set classfac = Nothing
End Sub
Set swDocMgr = classfac.GetApplication("license key") 'Specify your license key
Error: ActiveX can't create the object.
What about it ?
License key is wrong ?