I’m trying to learn about using ActiveX components in XOJO. I’m not a skilled programmer so I don’t know what I am doing or talking about, but I figure I would play with it and see what happens.
I have read that XOJO is not fully COM compliant, but that means nothing to me in terms of what can or cannot be done using ActiveX in XOJO. So I have looked at a VB example using ActiveX references from a program called SolidWorks Enterprise PDM. It is a document management system.
When inserting the ActiveX component into XOJO, I select the References tab and select PDMWorks Enterprise 2011 Type Library. At this point, a module called EDMLib shows in the right pane with classes, Enumerations, and Structures.
The first problem that I run into is that there are 2 structures that declare variables as a “Date” data type.
So my initial questions are:
- Is this a sign that I am running into XOJO not being fully COM compliant and it is pointless to continue, or is this just a bump that I can learn to overcome or perhaps it is a mountain that requires great effort?
- If this is a bump that can be overcome, how do you overcome this? I read that in VB the Date data type is 8 bytes, would something like this work:
change the declaration moDate As Date to
moDate As Int64
This change does allow me to get a program to compile and sort of work, but it has other problems. I may ask about those problems later depending on the answers to these 2 questions.
Just to be more complete, here are the contents of the two structures using the “Date” data type:
EdmBomVersion
meType As EdmLib.EdmBomVersionType
mlVersion As Integer
moDate As Date
mbsTag As CString
mbsComment As CString
EdmHistoryItem
meType As EdmLib.EdmHistoryType
moDate As Date
mlVersion As Integer
mlUserID As Integer
mlFileID As Integer
mlFolderID As Integer
mbsItemName As CString
mbsUserName As CString
mbsComment As CString
moData As EdmLib.EdmCmdData
Thanks for your help