Invoking a VB executable /DLL from Forms 6i
Hi Everyone,
We have a complete application (in the form of a product) in
Forms 6i. We need to integrate a licensing software with this
Forms product. This licensing software is built in VB. We
basically need to execute an executable and a DLL - ( I presume
that i can execute any external application/exectuable using the
HOST function ) - Please confirm if this can be done. And more
importantly how do I invoke a DLL which is supposed to return a
value to the Forms application.
All inputs are welcome - This is really really Urgent.
Ipsa.
I think you can use the ORA_FFI (Foreign Functions Interface) to
invoke functions in a DLL. I recently put together a small
package for calling HTML Help files using ORA_FFI. I can send it
to you if it would be of any help.
Regards,
Rajesh Jayaprakash
[email protected]
Similar Messages
-
URGENT- Need advice on executing scripts from Forms 6i
Hi all,
Quick background info:
I'm working on a conversion project from Forms 4.5 client/server applications to a three tier, web based Forms 6i environment.
We're running Oracle 8i DB on HP-UX machines, Oracle 9ias on HP-UX machines, and users access forms through Netscape
on Win2000 platform.
The problem:
I have a SQL execution interface form from which users have been able to run dynamic SQL scripts w/o having direct access to
a SQL Plus prompt (uses the 'HOST' command in 4.5). How can this functionality be implemented in the three tier environment?
Unless other options are available, my plan is to use a Java servlet to access the 8i database on the UNIX box and display
output on an html page. Is there a better/easier way?!
Any advice is appreciated...
FLM
Paychex, Inc.Thanks for the response,
I may be able to invoke the script from Forms using the HOST command, but how is the script output
displayed back to the browser?
FLM
[email protected]
You can probably still use the host to sqlplus, but this time it will run on the Forms Server.
You just need to make sure that the dynamic SQL files are uniquly identified for each customer. -
Dear all,
i want to execute a procedure from forms. my code is below for calling procedure, this code is working fine from the SQLPLUS, but not working from forms.
forms_ddl('execute audit_sessions('||''''||'et20'||''''||',sysdate,'||''''||'HELP'||''''||')');my procedure is below
CREATE OR REPLACE PROCEDURE audit_sessions(uname varchar2,logon_date date,APP_USER VARCHAR2) is
begin
insert into admin.session_audit values(uname,logon_date,APP_USER);
commit;
end;my table is below
SQL> desc session_audit
Name Null? Type
ACTIVE_DIRECTORY_USER VARCHAR2(30)
LOGON_TIME NOT NULL DATE
APPLICATION_USER NOT NULL VARCHAR2(30)kindly help. i am using oracle 10g database and forms version 9.0.4.0.19
Regards.
Edited by: Maahjoor on 09-Feb-2013 19:34
Edited by: Maahjoor on 09-Feb-2013 19:35
Edited by: Maahjoor on 09-Feb-2013 20:18Wa Alaikum Salam,
Dear Ahmad Rafiq,
it is compiled without error, so i think it should work, but now currently the forms is opened by some user,
as soon as i am able to delete the old one and paste the current one, i will update you and will mark the answer correct accordingly.
thank you so much dear. -
Hi I have to call a dll which returns some message by accepting a file name as input.
The plateform is Oracle form 6i deployed on oracle AS , and Oracle 8i DB as backend.
Kindly suggest , what can be best startegy-
call dll using form 6i in client server .
call dll using 3 tier deployement.
or make an ASP or JSP application
Please suggest.
PrashantCalling DLL using form 6i
Regards, -
Hello,
Sorry, I'm brazilian and my english isn't very good...
I'm trying to call some functions from a dll invoked by a trigger on event WHEN-BUTTON-PRESSED. I make a package as this:
---- Package Spec ----
PACKAGE anserlib IS
function autoconnect(p_connport in number) return boolean;
END;
---- Package Body ----
PACKAGE BODY anserlib IS
libhandle ora_ffi.libHandleType;
autoconnect_fhandle ora_ffi.funchandletype;
setprinton_fhandle ora_ffi.funchandletype;
setprintoff_fhandle ora_ffi.funchandletype;
res varchar2(200);
commport number;
function ff_autoconnect(fhandle ora_ffi.funchandletype, p_commport in number) return boolean;
pragma interface(C, ff_autoconnect, 11265);
function autoconnect(p_connport in number) return boolean is
begin
return(ff_autoconnect(autoconnect_fhandle,p_connport));
end;
begin
libhandle := Ora_Ffi.Load_Library('C:\Juarez\Anser\','Anser712.dll');
autoconnect_fhandle := ora_ffi.register_function(libhandle,'AutoConnect');
ora_ffi.register_parameter(autoconnect_fhandle, ora_ffi.C_INT);
ora_ffi.register_return(autoconnect_fhandle, ora_ffi.C_INT);
setprinton_fhandle := ora_ffi.register_function(libhandle,'SetPrintOn');
ora_ffi.register_return(setprinton_fhandle, ora_ffi.C_INT);
setprintoff_fhandle := ora_ffi.register_function(libhandle,'SetPrintOff');
ora_ffi.register_return(setprintoff_fhandle, ora_ffi.C_INT);
ora_ffi.generate_foreign(libhandle, 'anser');
exception
when ora_ffi.ffi_error then
--message(:bloco_teste.mensagem, acknowledge);
message(tool_err.message, acknowledge);
END;
and the trigger is:
declare
v_res boolean;
v_commport number;
begin
v_commport := 3;
v_res := anserlib.autoconnect(v_commport);
end;
When I run the form and press button appears the message (it appears in portuguese to me, maybe the text is not the same in english, but i'll try to translate):
FRM-40734: Internal Error: occours a PL/SQL error.
Someone have an idea to help me...?
Thanks vry much!!! :)In my opinion this error is something like 'General Protection Fault error' in Windows. I sow this error when my DLL worked with memory incorectly or called OCI functions which don't work under Forms Runtime.
I think the problem might be caused by a mistake inside the DLL. The other problem may be that you use incorect calling conversion. For instance, the default calling conversion in Borland C Builder or Delphi is fastcall, not cdecl.
p.s.
1. Sorry for my English too :).
2.
ora_ffi.generate_foreign(libhandle, 'anser');I'm not sure what ora_ffi.generate_foreign does exactly, because I have never used it. As far as I know it isn't needed for this code. I'd recomend you to remove this line from your program. -
Error executing reports from forms
Hi,
Iam trying to launch reports9i from forms9i,
Iam getting following error,
500 Internal Server Error
java.lang.StringIndexOutOfBoundsException: String index out of range: 0
at java.lang.String.charAt(String.java:444)
at oracle.reports.rwclient.ServletCmdMgr.getJobId(ServletCmdMgr.java:3131)
at oracle.reports.rwclient.ServletCmdMgr.handleCmdGetjob(ServletCmdMgr.java:1255)
at oracle.reports.rwclient.CommandManager.handleWebCommand(CommandManager.java:92)
at oracle.reports.rwclient.ServletCmdMgr.handleWebCommand(ServletCmdMgr.java:278)
at oracle.reports.rwclient.RWClient.handleWebCommand(RWClient.java:915)
at oracle.reports.rwclient.RWClient.processRequest(RWClient.java:1398)
at oracle.reports.rwclient.RWClient.doGet(RWClient.java:349)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:65)
at oracle.security.jazn.oc4j.JAZNFilter.doFilter(Unknown Source)
at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:604)
at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:317)
at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:790)
at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.AJPRequestHandler.run(AJPRequestHandler.java:208)
at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.AJPRequestHandler.run(AJPRequestHandler.java:125)
at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:186)
at java.lang.Thread.run(Thread.java:534)
Can anyone help me in this regard,
Thanks and regards,
Avinash,
Pune.
India."Iam trying to launch reports9i from forms9i"
your forms version is 10g :-) -
Hi
i am using oracle 8i database and form 6i in client sever mode. Can I call a custom dll form oracle forms.
Can any one please help , how to do it.
Prashantfirst register the dll into registry through regsvr32.exe
then u can u use it as Activex object and its prcedures so known as methods availabe to invoke in forms 6i
import ActiveX Control methods and events:
1 Choose ProgramOLE Importer to display the OLE Importer dialog box.
2 Select the desired OLE Class, then select the desired OLE methods and events.
3 Click OK.
Hope it helps!
Message was edited by:
Fiz Dosani
Message was edited by:
Fiz Dosani -
Executing DLLs from Java using JNI vs Runtime.exec()
I am trying to understand the best way to execute a dll using java. The dll I am testing with takes a few input parameter. If I use JNI with System.loadLibrary("dll"); what do I need to do to pass the arguements in as well? Can I just add the arguements in the java code like private int xyz = "value"; and expect that the dll will accept them or is there special definitions I have to set up in the dll to make it work?
Alternatively I was looking at using Runtime to execute the dll by using Runtime.exec("dll param1 param2",env,filePath); Does anyone know if there are drawback to doing it this way vs. using JNI or is this just as efficient? Any help would be appreciated.You seem to be confused...
"execute a dll using java"
Unless I'm mistaken, a dll is not executable. A dll is a library of code. This code has (hopefully) some well-defined entry points (declared in a header file somewhere) which you must call in a C/C++ file. The arguments you pass to the dll will come from java through JNI.
As far as your understanding of this entire process, it is obviously confused beyond the scope of a simple reply. I recommend you read the examples and ALL of the documentation available here:
http://java.sun.com/docs/books/tutorial/native1.1/index.html
When you get the/an example running (or just set up to run) then post your code and comments here for more help.
Ian -
Error while executing chart from form
Chart run well from local PC. but when i try to run it from Application server error accured " OG-1603: Unable to create PL/SQL Development Environment context"
Hi,
Whenever you create any view in webdynpro, the default text view element comes automatically. this is the reason for the presence of label.
you can go to the layout of the view and remove the textview element from the root UI transaparent container.
<u>Regarding the presence of blank IFrame:</u>
Please check if you have performed AFC setup before running the adobe interactive form application. the blank frame could be because of that.
Also try replacing the webserver name with its IP address in the application URL. This will help in the ADS to recognise your webserver.
Regards,
Chander -
Execute report from local drive from Forms 9i Apps
Hi - I have a requirement to run the report saved in windows network drive from FORMS 9i which is installed on AIX. looking forward for your help.
Requirement:
Forms application is invoked through the APPS server installed on AIX.
Report code RDF, REP is saved in Windows drive.
When i press a button in FORMS, reports in the windows drive should be executed and displayed to the users.
Thanks in advance.
regards,
Vikram.This is not possible. Forms/Reports 9i is web based, so the forms and reports need to be on the app server. You cannot run a report on a local drive (I assume you mean your own PC). Why don't you copy the report to the server?
You can try to map a directory on the AIX server to a shared Windows directory and put this directory in the reports_path variable.
However, you cannot run a Windows compiled REP file on an AIX server, so you need to save the RDF only. -
Report(3.0) not executing from Forms 6.0.
Hello
I am trying to run a report (developed in Report designer 3.0) from a form (developed in Form Builder 6.0) as follows :
-- message ('Before Report...');
-- run_product (REPORTS, 'proj', SYNCHRONOUS, RUNTIME, FILESYSTEM, listid ) ;
-- message ('After Report...');
DECLARE
repid report_object ;
rep VARCHAR2(100);
BEGIN
message ('Before Report...');
repid := find_report_object('PROJ');
rep := RUN_REPORT_OBJECT(repid);
message ('After Report...');
END;
I have tried both of these methods (Run_Product and Run_Report_Object) but nothing works. What is the difference between Run_Product and Run_Report_Object for report processing point-of-view ? It is displaying both messages but giving no error. The Properties of PROJ node in 'REPORTS' class are as follows :
Name : PROJ
File-Name : <full-path>/proj.rdf
Execution Mode : RunTime
Communication Mode : Synchronous
Data Source Block : Null
Query Block : Null
Report Destination Type : Screen
Destination Name : Null
I am not able to see the results even by executing in form builder.
Any help will be appreciated.
ManishHi Shay
Thanks for your reply. I have compiled the report (repname.rdf) in Report Builder 6.0 and trying to execute it from a form, developed in Form Builder 6.0, as follows :
PROCEDURE run_report IS
list_id ParamList;
run_date date;
repid report_object ;
repout varchar2(100) ;
BEGIN
run_date := sysdate;
list_id := Create_Parameter_List('input_params');
Add_Parameter(list_id, 'DESTYPE', TEXT_PARAMETER, 'FILE');
Add_Parameter(list_id, 'DESNAME', TEXT_PARAMETER, '/home/mgupta/orep.ps');
-- Run_Product(REPORTS, 'Full-Path/repname.rdf', synchronous, runtime, filesystem, list_id);
repid := find_report_object('repname');
repout := run_report_object(repid);
Destroy_Parameter_List(list_id);
END;
I have tried both methods (Run_Product and Run_Report_Object) but nothing works. What is the difference between Run_Product and Run_Report_Object for report processing point-of-view? Note that I have given full path for Run_Product while report-name is given for Run_Report_Object. The full path is also given in the property palette report. It is displaying both messages but giving no error. The Properties of REPNAME node of 'REPORTS' class in Object Navigator of specified form are as follows :
Name : REPNAME
File-Name : <full-path>/repname.rdf
Execution Mode : RunTime
Communication Mode : Synchronous
Data Source Block : Null
Query Block : Null
Report Destination Type : Screen
Destination Name : Null
This report is running fine if I execute it in Report Builder but not running thru form.
Any help will be appreciated.
Manish -
How to execute Pro*C file from form
Hi All !
I have one pro*c file(.pc & .exe) . How I can execute this file from form.
Regards,
NeerajI think you could use Ora_Ffi package too. Make sure that you use correct version of Pro/C.
I think you should use Pro/C version 8.0.x with Forms 6.0. I don't use Forms 6i, but I think it is the same for it too. -
HOW CAN I EXECUTE DINAMIC SENTENCES FROM FORMS
HOW CAN I EXECUTE DYNAMIC SENTENCES FROM FORMS.
Ex.
I would like to execute this commands from table SENTENCES
COL1
set_item_property (item1, enabled , property_true )
set_item_property (item2, enabled , property_true )
set_item_property (item3, enabled , property_false )
Regards
Message was edited by:
jcruizcarrera
Message was edited by:
jcruizcarrera... but you could imagine a sort of workaround...
PROCEDURE Set_Item
PC$Item In Varchar2
,PN$Property In Number
,PC$Value In Varchar2
) IS
BEGIN
Set_Item_Property( PC$Item, PN$Property, PC$Value ) ;
END;That you can call like this:
Set_Item( 'BL.BUTTON', LABEL, 'Hello' ) ;Francois -
Hello, how is it possible to execute a sql file from forms without using sqlplus, because we have only the forms runtime on our pc.
We can't use forms_ddl because we have a very big sql script for creating a package.
Please help,
GJStrange, whenever I have installed forms I got sqlplus too without asking for it. If it is not installed, wouldn't your best bet be to install it ?
-
Hi All,
I have to execute one DLL from ABAP, I have pass one file txt to parameters and execute the DLL.
Any could help me?Check this:
Re: How to call a FrontEnd DLL in ABAP Program
http://sap.ittoolbox.com/groups/technical-functional/sap-dev/vb-function-module-or-dll-in-abap-programming-1659211
http://nonet.dyndns.org/b2e/blogs/index.php/2005/10/30/calling_dll_functions_within_sapgup_via?blog=5
Maybe you are looking for
-
SAP Query with Logical databse
Hi All, I'm developing one report by SAP Query using with logical database BRM to pick the accounting documents. But I would like add some kind of where condtion for one of field for BKPF table. Is there way to achieve this by using logical database
-
Will VoiceOver read outline level labels in Pages document?
I have an outline such as Animals 1) Mammals a) dogs b) cats c) horses 2) Reptiles a) snakes b) iguanas and I want VoiceOver to read the levels labels outloud as it reads the outline contents. Such as: One Animals a dogs b ca
-
Query link Freight Charges RDR2
Hi Experts, I have did the queries as below but i have a problem to link to RIR2 which is Freight charges. I have tried after i linked the result is no correct. Please Kindy advise. SELECT T0.LineStatus AS 'Row Status', T1.DocDate AS 'Posting Date',
-
Adobe CS5 Updates fails !!! There was an error downloading this update HELP
Adobe CS5 Updates fails !!! There was an error downloading this update HELP (Windows)
-
Adobeforms (pdf is not abre with fillable = ' x')
Hello!! I am making a Adobeforms and I have the following problem: I have made a Adobeforms interactive (a Matchcode and all Ok can be introduced texts, be deplegar) the subject that when to quier to make keep like from the pdf when thro