This should be done in C #
My ELO hierarchy looks like this.
The folder FOLDER2 contains a text document. This is searched for and the object ID is returned. From this I get also the object ID "1234" for the FOLDER2.
Now there is in the folder TEXTFILES important text documents I would like to download.
Now to my question, if I have the object ID of FOLDER2, how can I find out which object ID of the folder TEXTFILES has to read out all data or download it there?
EditInfo ed = conn.Ix.checkoutDoc(pObjID, pDocID, EditInfoC.mbDocument, LockC.NO); DocVersion dv = ed.document.docs[0]; String outFile = System.IO.Path.GetTempFileName() + "." + dv.ext; conn.Download(dv.url, outFile); String url = dv.url;
Here is the code on how to download a file. There are the methods dv.relativeFilePath
, dv.physPath
so I could read the path to end up simply ELO / FOLDER1 / FOLDER2 / TEXTFILES could attach to the path to download the files
1 Answers
Answers 1
I was not able to find any official public documentation on your ELO
API. I even not sure what the ELO
stands for except that there is an "Indexserver Programming Guide" e-book offered at https://www.elo.com/wcm/en/service/elo-e-books If you can provide such a link, we (the SO community) probably will be able to answer your question better.
The only API reference I found that seems to match your short code example is Java API (unoficially) published at http://datigapowa.free.fr/javadoc8.00.036/. I assume that C# API is quite similar to the Java one described there and it looks like your conn.Ix
is of type that matches for IXServicePortIF
class as described at http://datigapowa.free.fr/javadoc8.00.036/de/elo/ix/client/IXServicePortIF.html. At least according to http://datigapowa.free.fr/javadoc8.00.036/index-all.html this is the only class that has checkoutDoc(ClientInfo, String, String, EditInfoZ, LockZ)
method.
So looking into IXServicePortIF
you may find interesting methods findFirstSords(ClientInfo ci, FindInfo findInfo, int max, SordZ sordZ)
, findNextSords(ClientInfo ci, java.lang.String searchId, int idx, int max, SordZ sordZ)
and mysterious processFindResult(ClientInfo ci, java.lang.String searchId, ProcessInfo procInfo)
. The findFirstSords
accepts a parameter of FindInfo
class which in turn has a parameter of FindChildren
class and it seems to be responsible for search through folders.
On the other hand, return value of the findFirstSords
is FindResult
which contains
- a collection of plain string
ids
- a collection of
Sord
which in turn features a few potentially interestings "IDs" such as justid
anddoc
some of which is might be what you need.
Note also that "See also" section of findFirstSords
documentation references some examples including C# one called FindChildren.cs.txt
Hope this helps.
0 comments:
Post a Comment