Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Java Samples to start a workflow

Status
Not open for further replies.

DilipN

Programmer
Jan 28, 2005
17
US
Hi ,

I am a newbie to livelink. I went through its API documentation but its really hard to understand.
Could someone please provide me a sample java code to start a work-flow.
This sample should take a file from my local system and attach it to the workflow and initiate/start a workflow.

i did see one example from
but this example is not helpfull.

I will appreciate if someonce can provide me such example.

Thank you,

Dilip.
 
Unfortunately I am the author of that piece.Why don't you try to get your hands on Easylapi or slapi which probably hides a lot of detail from the programmer.Livelink api expects you to know most of the aspects of livelink.There is no shortcut,Most of the piece in my code should be still usable if you can grasp the concept
Code:
login  to livelink(every api user does this)
user session is created
access library workspace(then only you can access the map object
get the map object
start the workflow
Load a map using this declaration
flow.LoadMap(volumeID,objectID,versionID,map )
The map will be your return value
Start Workflow using this
workid will be returned to you
StartWorkflow(map,name,additions,workID )
then access the workflow for more
I know it is too much but unless you get to know livelink api and its arcane objects it is kind of difficult.You can
aslo contact OT or get lapi training also.If you so desire I will work in my spare time trying to concoct a better sample for you.


Well, if I called the wrong number, why did you answer the phone?
James Thurber, New Yorker cartoon caption, June 5, 1937
 
Thank You very much for your help

I think i will follow the steps you mentioned and see how far i can go. Your example in does help to understand how to use the workflow object. it is really helpfull.

My main concern is to attach a file from local system. Actually even in API's(that i found) they talk of attaching a folder id(from livelink) but not a file from local system.

I will check for the training cost and duration.

Thank you once again. please post the sample code whenever
you have time. Incase i am unable to solve it i can refer your code.

Thank You very much.

Dilip.
 
it is the classic chicken and egg problem.You cannot attach a file system object before a workflow instance,having an attachments volume is created.Livelink is RDBMS based so all info is in its tables.So before an object(it could be documents,folders,wfattchments,projects,literally anything)
the software has to allocate a node for it ,then insert values corresponding to the object being created.I know certainly this does not help but once you get to know livelink,its schema then it is a piece of cake.When you hear API's people tend to use it as a black box approach which is still some time away.For consolation all I can think off is its very versatile architechture,very scalable.It offers api's in all other languages(VB,C++,C#,java my fav).Try doing simple things and observing the livelink interface of things you accomplished
using your code and that is a sure way of feeling succesful
with the product

Well, if I called the wrong number, why did you answer the phone?
James Thurber, New Yorker cartoon caption, June 5, 1937
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top