Home » Developer & Programmer » Forms » open exe file from a button (forms 10g)
open exe file from a button [message #279790] Sat, 10 November 2007 05:19 Go to next message
emadnabil
Messages: 163
Registered: August 2007
Senior Member
hii all

i want to open an exe file by pressing on a button on my form

is there any command to open an exe file
Re: open exe file from a button [message #279792 is a reply to message #279790] Sat, 10 November 2007 05:29 Go to previous messageGo to next message
alijeyan
Messages: 180
Registered: January 2007
Location: IRAN
Senior Member
in Trigger WHEN_BUTTON_PRESSED
test this :

 DECLARE
	APPID PLS_INTEGER;
BEGIN
---- Open Calculator when button pressed
APPID :=DDE.APP_BEGIN ('\path\CALC.EXE',DDE.APP_MODE_Maximized);
END;


ALI
Re: open exe file from a button [message #279801 is a reply to message #279792] Sat, 10 November 2007 08:47 Go to previous messageGo to next message
Littlefoot
Messages: 20897
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Additionally, and if applicable to your situation: there's a HOST built-in which can be used to execute operating system commands:
host('c:\windows\system32\calc.exe');
Re: open exe file from a button [message #279863 is a reply to message #279790] Sun, 11 November 2007 03:12 Go to previous messageGo to next message
emadnabil
Messages: 163
Registered: August 2007
Senior Member
Thanks for your replies

i used the host command
but when i run the application and press the button that execute the command host it opens the exe file on the server side not client side

Re: open exe file from a button [message #279864 is a reply to message #279863] Sun, 11 November 2007 03:16 Go to previous messageGo to next message
alijeyan
Messages: 180
Registered: January 2007
Location: IRAN
Senior Member
Hi

Please Use My Post .

ALI
Re: open exe file from a button [message #279871 is a reply to message #279790] Sun, 11 November 2007 05:08 Go to previous messageGo to next message
emadnabil
Messages: 163
Registered: August 2007
Senior Member
I tried your post
but still not working
the same problem still exists
Re: open exe file from a button [message #279886 is a reply to message #279790] Sun, 11 November 2007 08:06 Go to previous messageGo to next message
emadnabil
Messages: 163
Registered: August 2007
Senior Member
I still have the same problem
i cannot see the exe file running on the client side
it runs only on the server side
Re: open exe file from a button [message #280528 is a reply to message #279886] Wed, 14 November 2007 00:10 Go to previous messageGo to next message
djmartin
Messages: 10180
Registered: March 2005
Location: Canberra ACT Australia
Senior Member
Account Moderator
Try using the 'client_host' command.

David
Re: open exe file from a button [message #281734 is a reply to message #279790] Mon, 19 November 2007 02:57 Go to previous messageGo to next message
emadnabil
Messages: 163
Registered: August 2007
Senior Member
thanks for your reply

but i used client_host
in this command

client_host('\\192.168.2.206\D$\SDSSREPORTS.EXE');

and in compilation it give me:
identifier 'client_host' must be declared
Re: open exe file from a button [message #281781 is a reply to message #281734] Mon, 19 November 2007 05:21 Go to previous messageGo to next message
Maaher
Messages: 7062
Registered: December 2001
Senior Member
Client_host is part of WebUtil.

MHE
Re: open exe file from a button [message #281806 is a reply to message #279790] Mon, 19 November 2007 06:33 Go to previous messageGo to next message
emadnabil
Messages: 163
Registered: August 2007
Senior Member
thanks for your reply

is this syntax command correct
client_host('\\192.168.2.206\D$\SDSSREPORTS.EXE');


do i need to a declartion
i got an error of invalid identifier
when compile this code

Re: open exe file from a button [message #281814 is a reply to message #281806] Mon, 19 November 2007 06:51 Go to previous messageGo to next message
Maaher
Messages: 7062
Registered: December 2001
Senior Member
You need to attach webutil.pll to use CLIENT_HOST. The link I posted provides more information. I never used client_host myself but it's possible that you need to do some more tweaking (like import a Java class).

MHE
Re: open exe file from a button [message #281844 is a reply to message #279790] Mon, 19 November 2007 08:45 Go to previous messageGo to next message
emadnabil
Messages: 163
Registered: August 2007
Senior Member
I tried your post
but it when i run the application it gives me a message of "please achnowledge"

and don't continue openning the file
Re: open exe file from a button [message #281890 is a reply to message #281844] Mon, 19 November 2007 18:12 Go to previous messageGo to next message
djmartin
Messages: 10180
Registered: March 2005
Location: Canberra ACT Australia
Senior Member
Account Moderator
Please search this forum for 'client_host' to get an idea of how other people have handled this problem.

Also have a look at 'dde app_begin'.

David
Re: open exe file from a button [message #282179 is a reply to message #279790] Wed, 21 November 2007 01:28 Go to previous messageGo to next message
emadnabil
Messages: 163
Registered: August 2007
Senior Member
thanks for your reply

'DDE.APP_BEGIN' is openning the text file on application server
not on the client PC


and again when i used 'client_host' but it when i run the application it gives me a message of "please achnowledge" in the runtime
Re: open exe file from a button [message #282407 is a reply to message #282179] Wed, 21 November 2007 23:02 Go to previous messageGo to next message
djmartin
Messages: 10180
Registered: March 2005
Location: Canberra ACT Australia
Senior Member
Account Moderator
Please post your code.

Also confirm which version of Forms that you are running.

David
Re: open exe file from a button [message #282469 is a reply to message #279790] Thu, 22 November 2007 01:36 Go to previous messageGo to next message
emadnabil
Messages: 163
Registered: August 2007
Senior Member
I am using forms Version 10.1.2.0.2

the code is on trigger "WHEN-TREE-NODE-ACTIVATED"

iF :INTRO.TREE_VAL=33	then 
DECLARE 
U  VARCHAR2(10);
BEGIN 
  SELECT S.USER_ID INTO U
  FROM FND_USER S
  WHERE S.USER_NAME=:Global.uusername;

  INSERT INTO REP_HISTORY VALUES ('Daily Sales Report.rdf',U,:Global.uusername,SYSDATE);
  COMMIT ;
  client_host('\\192.168.2.206\D$\SDSSREPORTS.EXE');

end;

end if;


when i run the application it gives me a message of "please achnowledge" in the runtime


Re: open exe file from a button [message #282637 is a reply to message #282469] Thu, 22 November 2007 19:15 Go to previous messageGo to next message
djmartin
Messages: 10180
Registered: March 2005
Location: Canberra ACT Australia
Senior Member
Account Moderator
Try "client_host('CMD /C \\192.168.2.206\D$\SDSSREPORTS.EXE');"

David
Re: open exe file from a button [message #282917 is a reply to message #279790] Sun, 25 November 2007 01:38 Go to previous messageGo to next message
emadnabil
Messages: 163
Registered: August 2007
Senior Member
thanks for your reply

i made a form with one button
when pressing on this button it should execute the command of client_host


but i got this errors


the webutil object group is not available in this form
web util cannot work




webutil error : oracle.forms.webutil.host.hostbean not found
WEBUITL_HOST. execute will not work
Re: open exe file from a button [message #282928 is a reply to message #282917] Sun, 25 November 2007 03:16 Go to previous messageGo to next message
mudabbir
Messages: 235
Registered: April 2006
Location: Kuwait
Senior Member

You need to open webutil.olb and attach the webutil object from there to your form.

Mudabbir
Re: open exe file from a button [message #282948 is a reply to message #279790] Sun, 25 November 2007 07:53 Go to previous messageGo to next message
emadnabil
Messages: 163
Registered: August 2007
Senior Member
Thanks for your reply


i openned the webutil.olb but how can i attach it to my form
Re: open exe file from a button [message #283029 is a reply to message #282948] Mon, 26 November 2007 00:00 Go to previous message
mudabbir
Messages: 235
Registered: April 2006
Location: Kuwait
Senior Member

when you open the WEBUTIL.OLB, you will see WEBUTIL object in it. drag that object to your form to "OBJECT GROUPS". copy.

Mudabbir
Previous Topic: web forms 6i on IIS: client browser closed automatically
Next Topic: How to grant permission to a user
Goto Forum:
  


Current Time: Wed Dec 07 04:58:16 CST 2016

Total time taken to generate the page: 0.08441 seconds