Solved

Run a exe program in a form

Posted on 1998-11-16
4
3,233 Views
Last Modified: 2008-02-20
Hi !

If a  menu bar is activated in an Oracle form  version 4.5.7.1.6 I would like an .exe program to run in an own process.
I am working in NT4.0.
I start the program with host(system_command_string);
but you have to close the program to get back to the form.
I would like it to run at the same time.
Is it possible ?

0
Comment
Question by:annkal
  • 2
4 Comments
 

Accepted Solution

by:
jpotts earned 100 total points
ID: 1082566
The host command is more for running a command.
Use the DDE Package to run a concurrent application:

DECLARE
   AppID PLS_INTEGER;
BEGIN
   AppID := DDE.App_Begin('C:Prog.exe',DDE.APP_MODE_NORMAL);
END;

You can also use functions like DDE.App_End to end the app.
See Online Help for more details.
0
 

Author Comment

by:annkal
ID: 1082567
Hi !
I have done exactly like you but I ' get an answer
FRM -21011:PL/SQL unhandled exception ORA -106500.
I have the packages att the botton on my 'forms tree'
as built in Packages, but I' cant use it. Why?
0
 
LVL 3

Expert Comment

by:vlad_impala
ID: 1082568
The ORA-106500 message means that it cannot find the program you have told it to start.  Make sure you either use the full path, or that the program exists in a directory that is listed in you DOS path.

for example
AppID := DDE.App_Begin('c:\windows\notepad.exe',DDE.APP_MODE_NORMAL);
AppID := DDE.App_Begin('notepad.exe',DDE.APP_MODE_NORMAL);
would both work OK but
AppID := DDE.App_Begin('c:\notepad.exe',DDE.APP_MODE_NORMAL);
gives the ORA-106500 error.

Vlad
0
 

Author Comment

by:annkal
ID: 1082569
It works BUT I can't open the aplication with argument.
If I try from the command prompt:
c:\temp\Ides.exe -username my_user -password my_user connect_string mydatabas

it works but if I try that in the formprocedure

App.ID:=DDE.APP_BEGIN('c:\temp\Ides.exe -username my_user -password my_user connect_string mydatabas',DDE.APP_MODE_NORMAL);

it doesen't work. Does the package function add any garbage sign .
0

Featured Post

Networking for the Cloud Era

Join Microsoft and Riverbed for a discussion and demonstration of enhancements to SteelConnect:
-One-click orchestration and cloud connectivity in Azure environments
-Tight integration of SD-WAN and WAN optimization capabilities
-Scalability and resiliency equal to a data center

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This article started out as an Experts-Exchange question, which then grew into a quick tip to go along with an IOUG presentation for the Collaborate confernce and then later grew again into a full blown article with expanded functionality and legacy…
Using SQL Scripts we can save all the SQL queries as files that we use very frequently on our database later point of time. This is one of the feature present under SQL Workshop in Oracle Application Express.
This video shows setup options and the basic steps and syntax for duplicating (cloning) a database from one instance to another. Examples are given for duplicating to the same machine and to different machines
This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question