Attain Automation Question

I am using Attain 3.01 SQL. I have decided to implement my own web-based system for warehouse management using Cold Fusion and Pocket PC-based handhelds. I am looking for a way to execute a codeunit to post a purchase order for receiving only. The Cold Fusion application will fill in the receive quantity for each PO line. When finished, it needs to cause the codeunit to run to post the purchase order. Does anyone know how this can be done? I don’t want to have a timer based process running checking for orders that need to be posted. I want to be able to cause the post to be done and hopefully get results back. I’m wondering if Attain’s new shortcuts could do this somehow. Thank you. David Rochford Zesco Products 317-269-9300 x188 david@zesco.com

David, See the thread in this forum entitled “validating Navision externally”. I believe the last response by Paul Baxter addresses your question. Happy New Year! Dave Studebaker das@libertyforever.com Liberty Grove Software A Navision Services Partner

Thanks for responding. I don’t really understand that answer. It sounds like it might be possible to create a shortcut that would work but I don’t understand how from the answer. I need to simply execute the codeunit that is run when a user selects POST on a purchase order and then specifies post receiving only. I could create a new codeunit that executes the proper codeunit. There is not good documentation for the shortcut feature but I wonder if it can specify a codeunit object and the parameters that the codeunit needs. David Rochford Zesco Products 317-269-9300 x188 david@zesco.com

Hi David You could use a hyperlink They look like this: navision://client/run?database=d:%5Cattain%5Cdemodata%5Cgbdemodatadatabase.fdb%26company=CRONUS%20UK%20Ltd.%26target=Form%2021%26view=SORTING(Field1)%26position=Field1=0(20000)%26servertype=NAVISION But this would cause navision to start and run a form which I am sure is not what you want to do. You could do what you want with this form including receiving the item. I would think you are trying not to use Navision users or the navision interface so this does not achieve this. What you need to do is create some sort of interface between you web server and Navision. This is not as dificult as it sounds. You would have NAS running on your web server with a VB interface responding to event from your web server. Paul Baxter

I don’t mind using a Navision session for this and I don’t really want to spend big $ for NAS. Would it be possible to design a form that I could run from a hyperlink that would do the following? 1) Get a record that contains the number of the purchase order to post and update the record to indicate the post is in progress. This would be a custom table. 2) Call the purchase order posting codeunit to post the receipt. (The quantities would already be updated in the Purchase Lines tables by the web application). 3) Delete the post record from the custom table if the post was successful. This form would need to be able to work with no input required. I would be able to run the form from the object designer to test it and it would simply post the order and close the form. Is this possible? Thanks for the help so far. David Rochford Zesco Products 317-269-9300 x188 david@zesco.com

In reading the Application Designers Guide, it sounds like it might be better to design a report that does what I want, rather than a form. I know I can create a hyperlink to a report or I can use Expandits launch utility to run the report. Now I just need to figure out if a report can do what I need to do. David Rochford Zesco Products 317-269-9300 x188 david@zesco.com

Yes and Yes. Look at the hyperlink and make one work %5C = \ %20 = Space %26 = . Paul Baxter

I have the report working and I’ve created a hyperlink to run it. The only problem is that Navision stays running and I have to exit it manually. I need Navision to automatically terminate after running the report. I don’t see anything in the documentation about a parameter like this. Does anyone have an idea? Thanks, David Rochford Zesco Products 317-269-9300 x188 david@zesco.com

Sorry David but I don’t know how to close an Attain client from within Attain. Paul Baxter

You could use Expand IT’s program or you could simply create a small app which selects the appropriate application window and then sends keystrokes to close the application. Hope this helps.