I'm writing a macro to get active document ownership with one push.
So I need to read active connection info (user) for this. Is this possoble and how to do it?
I have tried following code and it works but the problem is that there are many different users and the ownership should belong to the one that runs this macro.
Dim connection As PDMWConnection
Set connection = CreateObject("PDMWorks.PDMWConnection")
connection.Login pdmwUserName, "****", pdmwServer
Of course I can ask username + password for this but one has given these already while started SW+Workgroup PDM so it would be an additional task each time running the macro. Another option might be a setup file for each user but don't like the idea storing passwords into a file.
SolidworksApi macros