Displaying Progress of an ADO Command

grizlE
01-31-2002, 07:44 AM
I currently have a program that FTPs text files to our FTP server, which happens to be an iSeries (AS/400). Once the FTP is complete, I execute a ADO command, which calls a CL program on our iSeries, which in turn calls several other RPG programs that, among other things prints a report based on the data in the files that were FTP'd. My problem is, I am having trouble finding a way to track the status of what is going on once the ADO command executes.
My first thought was to use a progress bar, but the trouble I am running into is the program stops at the command.execute statement in my code until all of the programs on the AS/400 are done running.
Currently I am thinking about displaying a form similar to the one that displays when copying information from folder to folder. You know, the one with one folder on the left and the other one on the right and shows the document going from the left folder to the right folder. I was going to change the recieving icon to an icon of an AS/400. The problem I am having is I'm not entirely sure how to go about doing that.

One thing to keep in mind is that the program works fine, so I don't want to make any big changes. I am only working on making the interface more meaningful.

If you have any ideas, or know of a better way to accomplish what I am trying to do please let me know.
Thanks!

Thinker
01-31-2002, 08:01 AM
The problem that the rest of us are having with making any
suggestions is ADO is to us a data access method, not a method
of remote procedure calls. All of the 'commands' I execute with
ADO are SQL statements, or stored procedures that execute SQLs
and return data or results. I guess your CL program is functioning
like a stored proc as far as ADO is concerned, but I don't know if
you can use the asynchronous execute methods to allow your
program to display some kind of status while executing.

Here is a link ArnoutV posted recently that talks about ADO
async execute. Link Here (http://support.microsoft.com/default.aspx?scid=kb;EN-US;q190988)

grizlE
01-31-2002, 08:50 AM
I guess I don't know of any other way to do remote procedure calls to an AS/400. CGI possibly? I wouldn't be surprised if there is an API somewhere that does.
I had toyed with the idea of using CallBacks or Events, but time is short and I can only think of 1 time I have ever used either of those and it was using components in MTS and Windows NT; nothing on a remote machine.
I have done some preliminary reading on how to use those with the AS/400 and the the best I could find is using data queue objects. Not familiar with those.
That would involve a drastic change. That is why I started thinking about sticking a form on the screen with a document moving from folder to folder. I figured the bright blinking lights and something moving on the screen would keep the user amused, and calm until the all of my OS/400 programs were done running.
That seems easy enough to do.
I could work on using the CallBack or Events technologies in my spare time and some day release a new version of my program.

Thanks for your input

Thinker
01-31-2002, 09:10 AM
The reason I suggested looking into async stuff was so that your
program could continue to do things like notify the user it was
still working. Otherwise, I guess you could find one of those
animated gif controls, slap it on the form, and load it with one of
those flying document gifs that MS likes to use.

grizlE
01-31-2002, 09:18 AM
I'll look into that. I totally forgot you mentioned that. I strayed off on a different idea. That probably would be more representitive of what was going on, rather that the animated form idea.
Thanks.

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum