cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

We are happy to announce the new Windchill Customization board! Learn more.

Automating creating documents in a library folder

mdebower
18-Opal

Automating creating documents in a library folder

I am in some uncharted waters, andneed some advice on the best method to automate creating library documents in Windchill. Here is the situation: I have a Windchill user in a purchasing role receiving quotations for parts everyday. We would like to create quote documents in a library folder so that engineers can easily access and link to those documents. The documents are typically PDFs, but could be EXCEL, or WORD files as well.

1. Get quotation from vendor and save to shared drive: U:\Quotes

2. (Some magic happens... automagically)

3. Quotation documents are in Windchill> Purchasing Library\External Quotes.

As you can see, I need some help with step two. 🙂 We subscribe to an ASP (Application Service Provider) for Windchill so I don't have access to the Windchill server. (At least not without undue hardship.) So any method would need to be run on a local client machine

- marc

10 REPLIES 10
MikeLockwood
22-Sapphire I
(To:mdebower)

Not sure I understand completely, but seems that you might have the purchasing user create the needed documents themselves directly in Windchill. Maybe set up a separate Library for these, with a simple (maybe 1 state) lifecycle. Those interested could subscribe to all here, or could have subfolders as needed.

Using the Create Multiple Documents icon and the Drag -n- Drop
functionality is pretty straightforward too.

> Not sure I understand completely, but seems that you might have the
purchasing user create the needed documents themselves directly in
Windchill. Maybe set up a separate Library for these, with a simple
(maybe 1 state) lifecycle. Those interested could subscribe to all
here,
> or could have subfolders as needed.
>

We are currently manually creating the documents in Windchill. I was hoping for a way to automatically have this done without user interaction.

Since the quotes all start in the same shared drive and get loaded into the same Windchill folder, it just seems like a little bit of a batchfile or script running on the client would work. I can create a script running on the client to automatically look for new files in the folder, but don't know how to get automatically load them in Windchill.


MikeLockwood
22-Sapphire I
(To:mdebower)

Only other suggestion then is to have the buyer create in Windchill "from template."

Since you don't have access to the server to create info*engine tasks, I'm
not sure there is a way you can automate it.

> Only other suggestion then is to have the buyer create in Windchill "from
> template."
>

Hi



There are few ways for accomplishing this. Especially the steps 6 and 7
below. If you want to do it by means of workflow following are the sequence
of the steps.



1. Enable auto numbering for the Windchill Document(WTDocument or one
of its sub-types)
2. Name the file as Windchill Document Name + any extension
3. Create a InfoEngine webject for creating a document and for
uploading the primary content.(Refer Windchill Adapter guide for IE Action
webjects)
4. Invoke the InfoEngine task from a Java wrapper code. With in the
code, set the folder location, any other default values for creating
documents
5. Map the shared folder to the Windchill server
6. Create a workflow for calling the Java wrapper code which gathers
the files in the shared folder, gets the file name and invokes the task for
creating and uploading
7. Include a timer robot with in the workflow for looping



These all are very higher level details. If you need any specific
information, please give me a call or drop me a line.





Thank you and have a great time.

Best Regards

Swamy Senthil

973 216 0456(M)

866 908 6561(F)

Swasen Inc

www.swasen.com

_____

If you can't do server side you will have to do client side with a scripted http client that replaces a human and web browser. This would defintely require a programmer who understands http protocol. Many langages provide libraries and APIs to speed this up.

David DeMay


Sent from my Verizon Wireless BlackBerry

Marc,

Can you describe the behavior you would like to see in step two.

I have thought of something that might get the job done for you but as
always automation requires programming logic.

My idea is as follows.

Create a workflow with a loop.
The loop would, using either a sync robot or a timer robot, check the
U:\Quotes location for new quotes. (This workflow would have to always be
running
An ArrayList<strings> would store the file names of the new quotes.
If the size of quotes ArrayList = 0 the workflow goes back to the synch or
timer robot.
If the size of quotes ArrayList is greater than 0 a loop would be invoked
that would create a WTDocuments and add the file from U:\Quotes as the
content.
The quote file would then be either moved from U:\Quotes to backup
location or deleted from U:\Quotes so that it is not processed or deleted.

This is certainly doable. I'm not sure about your numbering, naming
convention for the WTDocument quote object but if you wanted you could
certainly use the quotes filename. Several detail would have to be worked
out and your application sever would of course need access to the
U:\Quotes location using \\quote server name\Quotes.

David


David,

You are right on track for what I was thinking for my step two. However, my big unknown is how to create the WTDocuments without user interaction AND from a client machine. (Your step 5.) As I stated originally, access to the Windchill server is limited and costly because we are an ASP subscriber.

- marc


I'm just thinking out loud here, what about using the URL robot to be able
to access your files from the remote server?


> David,
>
> You are right on track for what I was thinking for my step two. However,
> my big unknown is how to create the WTDocuments without user interaction
> AND from a client machine. (Your step 5.) As I stated originally,
> access to the Windchill server is limited and costly because we are an ASP
> subscriber.
>
> - marc
>
>
>
Top Tags