Code Comments

Programming Forum and web based access to our favorite programming groups.
For Programmers: Free Programming Magazines | New: Database administration forum
Registration is free! Edit your profileCalendarFind other membersFrequently Asked QuestionsSearch -> 
Post New Thread











Thread
Author

Run APL function on DoS Command line
Hi APL experts,

I am using APL+Win 3.6 on Windows 2000/XP. I want to run an APL function on 
the DOS command line (without opening the application window).

On a DOS command line now I can do the following:
   c:\path\aplw "c:\aplwin36\tools\myWorkSpace.w3" 200M

What I actually want to do is to run a function, which is defined in the wor
kspace and takes one parameter. Eventually I want to run this in a script.

How can I achieve this? Please help!

Larry

Report this thread to moderator Post Follow-up to this message
Old Post
brookmeade
06-02-05 12:36 AM


Re: Run APL function on DoS Command line
I think that 3.5 supports automation.

1. Copy this code & paste it in a text file.

set apl = createobject("APLW.WsEngine")
apl.SysCommand "load c:\Myws"
apl.Call "MyFn", 100 
set apl = nothing

2. Change the workspace name, function name and argument as required.
3. Save the text file with extension VBS e.g. APL.vbs
4. Type the file name at the command prompt & press enter or double click on
 the file name from within explorer.

Report this thread to moderator Post Follow-up to this message
Old Post
AA2e72e
06-03-05 04:08 PM


Re: Re: Run APL function on DoS Command line
Thanks AA2e72e for your reply!

Yes. I did exactly the same as you described below. It worked!
By the way, the APL 3.5 (or later) tech doc has more details on how to use A
PL+Win as an ActiveX Server to achieve this. 

Thanks again!

quote:
Originally posted by AA2e72e I think that 3.5 supports automation. 1. Copy this code & paste it in a text file. set apl = createobject("APLW.WsEngine") apl.SysCommand "load c:\Myws" apl.Call "MyFn", 100 set apl = nothing 2. Change the workspace name, function name and argument as required. 3. Save the text file with extension VBS e.g. APL.vbs 4. Type the file name at the command prompt & press enter or double click on the file na me from within explorer.

Report this thread to moderator Post Follow-up to this message
Old Post
brookmeade
06-03-05 04:33 PM


Re: Re: Re: Run APL function on DoS Command line
The code sample I gave you is using APL+Win as an ActiveX server!

The Scripting Engine is the CLIENT and APL+Win is the SERVER. 

Unfortunately, APL+Win as an ActiveX server has different syntax depending o
n whether the client is APL+Win (or another APL) or not APL. For a non apl c
lient, things get a bit tenuous because of the differences in ANSI & AV but 
you do have the advantage that there is only one APL+Win session.

Report this thread to moderator Post Follow-up to this message
Old Post
AA2e72e
06-03-05 05:24 PM


Sponsored Links




Last Thread Next Thread Next
Search this forum -> 
Post New Thread

APL archive

Show a Printable Version Send to friend Email This Page to Someone! subscribe to this thread Receive updates to this thread
Computer Consultants
Programming Jobs
Visual Basic Controls
SQL Server Programming
Webservices
Java Security
Visual Studio
C# Programming
Visual J++
Software engineering
Open source Software
Perl Programming
PHP Programming
ASP Programming
ASP .NET Programming
Visual Basic Programming
Windows Scripting Host
Java Programming
Java Help
Java Beans
VBScript
Cobol
MAC Applications
Unix Programming
Forum Jump:
All times are GMT. The time now is 06:47 PM.

 
Free MCSE Braindumps | Real Estate Topics

Programming forum archive

Copyrights CodeComments.com 2004 - 2006

Powered by vBulletin Copyright 2000-2006 Jelsoft Enterprises Limited.