shell to behave in synchronous manner

  • Thread starter Thread starter rraajjiibb
  • Start date Start date
R

rraajjiibb

My problem is this...


Since the

SHELL() availiable in VBA is asynchronus.


WHAT MY CODE IS DOING
--------------------------------
Actually a batch file is called through the Shell which in turn runs a
rsh on the unix machine and brings the file using the GET command.

Since it is diificult to predetermine the time taken to FTP ,in some
cases of file transfer the TEN SECONDS pause that I use in code is
exceeding thus causing trouble.

How to get around this problem???


.. Also I was thinking in the following direction to get around..


When we call SHELL(...) it returns a TASK ID assigned by the PC .Is
there a way to get the status of this TASK ID so that it can be
utilised to trigger the next line of the code ... instead of the timer
approach that I am currently using...


Thanks
:confused:
 
Hi,
The MS way http://support.microsoft.com/defaul...port/kb/articles/Q129/7/96.asp&NoWebContent=1

Since you mentioned FTP, you can also control IE and most all activity from VBA with the INET control including waiting for the "Done" command to be returned. Look for Microsoft Internet Control in VBA tools>references.



--
John
johnf 202 at hotmail dot com


| My problem is this...
|
|
| Since the
|
| SHELL() availiable in VBA is asynchronus.
|
|
| WHAT MY CODE IS DOING
| --------------------------------
| Actually a batch file is called through the Shell which in turn runs a
| rsh on the unix machine and brings the file using the GET command.
|
| Since it is diificult to predetermine the time taken to FTP ,in some
| cases of file transfer the TEN SECONDS pause that I use in code is
| exceeding thus causing trouble.
|
| How to get around this problem???
|
|
| . Also I was thinking in the following direction to get around..
|
|
| When we call SHELL(...) it returns a TASK ID assigned by the PC .Is
| there a way to get the status of this TASK ID so that it can be
| utilised to trigger the next line of the code ... instead of the timer
| approach that I am currently using...
|
|
| Thanks
| :confused:
|
|
| ---
| Message posted
|
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top