The EdmGetCmdFlags.Egcf_Lock argument tells CreateTree that you wish to check out, i.e. lock, the files. If you just want to get local copies, you would use the EdmGetCmdFlags.Egcf_Nothing argument.
EPDM 2010 SP2
That's what I thought and that's what I tried. Sadly, I still failed.
Thanks for the answer, at least it confirms my intuition.
So is your code just getting copies of files and not locking them or is it not working at all?
In many cases, it "UnGets" the file, showing -/6 version instead of 6/6. But never checks it out. There must be some other problem in the code.
Your loop should create an array of EdmSelItem objects. After the loop is finished, pass that array as the argument to AddSelection.
Dim batchCheckout As IEdmBatchGet
batchCheckout = thisVault.CreateUtility(EdmUtility.EdmUtil_BatchGet)
Dim varCheckout(0) As EdmSelItem
Dim strFoo As String = ""
Dim index as integer = 0
For Each r (my loop)
0index).mlDocID = r("ItemID")
0index).mlProjID = r("ProjectID")
index = index + 1