Home » Developer & Programmer » Forms » Issue with D2KWUTIL.PLL (Oracle 6i forms, 6.0.8.25.2, WINDOWS XP )
Issue with D2KWUTIL.PLL [message #404889] Mon, 25 May 2009 04:05 Go to next message
psenthilkumar4
Messages: 3
Registered: May 2009
Location: SINGAPORE
Junior Member
When i run the below prcoedure, excel.exe not intialised

i have attached d2kwutil.pll in lib & placed source in form60_path directory

The output is

"'Registry Path : HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\Excel.exe not Found"



BEGIN
set_application_property(cursor_style,'busy');
Begin
lv_Excel_path := Win_API_Environment.Read_Registry('HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\Excel.exe','Path');
Exception
When others then
message('Registry Path : HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\Excel.exe not Found');
Raise Form_trigger_Failure;
End;

v_xl_fname:= 'C:\SOURCE.XLS';
Lv_filename:= 'C:\TEST.XLS';

Begin
appid := dde.app_begin(lv_Excel_path||'\Excel.exe',dde.app_mode_minimized);
-- establish the Excel
Exception
when dde.dde_app_failure then
appid := dde.app_begin('excel.exe',dde.app_mode_minimized);
-- establish the Excel
End;
-- establish the Excel
while not conv_est loop
begin
ConvID := DDE.INITIATE('EXCEL', 'system');
conv_est := true;
exception
when dde.dmlerr_no_conv_established then
conv_est := false;
end;
end loop;
BEGIN
Win_Api_Utility.Copy_File(v_xl_fname,Lv_filename,TRUE);
EXCEPTION
WHEN OTHERS THEN
message(sqlerrm||'-'||SQLCODE);
END;
file_name_ := '[open("'||Lv_filename||'")]';
dde.execute(convid,file_name_,90000);
sheet_name_ := 'LCL';
docid := DDE.INITIATE('EXCEL', sheet_name_);
row_start:=10;

Begin
For C2 In C1
Loop

DDE.poke(docid, 'R'||row_start||'C3',Nvl(C2.BKG_NO,' '), DDE.CF_TEXT,10000);--Permit#
row_start :=row_start+1;
End Loop;
Exception
When Others Then
Null;
End;
-- close the Excel file
dde.terminate(docid);
dde.terminate(convid);
Convid := DDE.INITIATE('EXCEL', 'system');
-- file_name_ := '[close("'||v_xl_fname ||'")]';
file_name_ := '[close("'||Lv_filename ||'")]';
dde.execute(convid,file_name_,90000);
dde.terminate(convid);
dde.app_end(appid);
set_application_property(cursor_style,'DEFAULT');
Message('File generated successfully.');

exception
when dde.dde_app_failure then
message('windows app. cannot start');
exit_form(no_validate);
when dde.dde_param_err then
message('a null value was passed to dde');
exit_form(no_validate);
when dde.dmlerr_notprocessed then
message('a transaction failed');
exit_form(no_validate);
when dde.dmlerr_no_conv_established then
message('no conversation est.');
exit_form(no_validate);
when others then
message('no conversation est.');
set_application_property(cursor_style,'DEFAULT');
END;


please help to resolve
Re: Issue with D2KWUTIL.PLL [message #404967 is a reply to message #404889] Mon, 25 May 2009 20:26 Go to previous messageGo to next message
psenthilkumar4
Messages: 3
Registered: May 2009
Location: SINGAPORE
Junior Member
Hi,

Cany any one let me know the

Intial setup for using d2kwutil.pll files (is .dll files are needed?)

My issues is when i call win_api_environment.read_registry it doesnt return any value , i also tried using Win_Api_Utility.Copy_File which is also no results.

Steps i have done.

1.Place the d2kwutil.pll in the source folder where all my (.fmx, .rep, .dll files placed).
2.ATTACHED d2kwutil.pll in attach libraries (remove path =no)
Re: Issue with D2KWUTIL.PLL [message #406267 is a reply to message #404967] Wed, 03 June 2009 01:28 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
Have you solved your problem? Try using the non-default option 'yes' when asked the 'remove directory' question.

David
icon5.gif  Re: Issue with D2KWUTIL.PLL [message #415152 is a reply to message #404889] Sat, 25 July 2009 07:29 Go to previous messageGo to next message
saeid
Messages: 22
Registered: May 2008
Junior Member
Hi all ,
I have this problem too.
I attached d2kwutil.pll and copy it to "my-computer"\\TOOLS\OPEN60\PLSQLLIB and server . this code is in when-button-pressed trigger.

lv_pdf_path:= Win_API_Environment.Read_Registry('HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\AcroRd32.exe','Path');

but at runtime has ocored an error with this message
"PDE-DFF003 can`t open library : D2kwut32.dll"

please help me.Thanks in advance.

[Updated on: Sat, 25 July 2009 07:35]

Report message to a moderator

Re: Issue with D2KWUTIL.PLL [message #415212 is a reply to message #404889] Sun, 26 July 2009 07:07 Go to previous messageGo to next message
saeid
Messages: 22
Registered: May 2008
Junior Member
Hi all,
I could run it without "Not found" error.
if i run form with debug(shift+ctrl+R) result is correct .
but if i run form normally (Ctrl+R) ,appears an error
'FRM-40734'.

can any one help me?please...Sad
Re: Issue with D2KWUTIL.PLL [message #415248 is a reply to message #415212] Sun, 26 July 2009 15:55 Go to previous messageGo to next message
Littlefoot
Messages: 21818
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Try to first compile all (<Ctrl + Shift + K>) and then run the form.
icon12.gif  Re: Issue with D2KWUTIL.PLL [message #415756 is a reply to message #415248] Wed, 29 July 2009 02:50 Go to previous messageGo to next message
saeid
Messages: 22
Registered: May 2008
Junior Member
Thanks littlt_foot.
i found answer of my problems.it is very interesting...
i have used update_patch in form 6i when delete it .my form ran correct. Smile
Re: Issue with D2KWUTIL.PLL [message #494610 is a reply to message #415756] Wed, 16 February 2011 00:46 Go to previous message
psenthilkumar4
Messages: 3
Registered: May 2009
Location: SINGAPORE
Junior Member
The output is

"'Registry Path : HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\Excel.exe not Found"



BEGIN
set_application_property(cursor_style,'busy');
Begin
lv_Excel_path := Win_API_Environment.Read_Registry('HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\Excel.exe','Path');
Exception
When others then
message('Registry Path : HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\Excel.exe not Found');
Raise Form_trigger_Failure;
End;

v_xl_fname:= 'C:\SOURCE.XLS';
Lv_filename:= 'C:\TEST.XLS';

Begin
appid := dde.app_begin(lv_Excel_path||'\Excel.exe',dde.app_mode_minimized);
-- establish the Excel
Exception
when dde.dde_app_failure then
appid := dde.app_begin('excel.exe',dde.app_mode_minimized);
-- establish the Excel
End;
-- establish the Excel
while not conv_est loop
begin
ConvID := DDE.INITIATE('EXCEL', 'system');
conv_est := true;
exception
when dde.dmlerr_no_conv_established then
conv_est := false;
end;
end loop;
BEGIN
Win_Api_Utility.Copy_File(v_xl_fname,Lv_filename,TRUE);
EXCEPTION
WHEN OTHERS THEN
message(sqlerrm||'-'||SQLCODE);
END;
file_name_ := '[open("'||Lv_filename||'")]';
dde.execute(convid,file_name_,90000);
sheet_name_ := 'LCL';
docid := DDE.INITIATE('EXCEL', sheet_name_);
row_start:=10;

Begin
For C2 In C1
Loop

DDE.poke(docid, 'R'||row_start||'C3',Nvl(C2.BKG_NO,' '), DDE.CF_TEXT,10000);--Permit#
row_start :=row_start+1;
End Loop;
Exception
When Others Then
Null;
End;
-- close the Excel file
dde.terminate(docid);
dde.terminate(convid);
Convid := DDE.INITIATE('EXCEL', 'system');
-- file_name_ := '[close("'||v_xl_fname ||'")]';
file_name_ := '[close("'||Lv_filename ||'")]';
dde.execute(convid,file_name_,90000);
dde.terminate(convid);
dde.app_end(appid);
set_application_property(cursor_style,'DEFAULT');
Message('File generated successfully.');

exception
when dde.dde_app_failure then
message('windows app. cannot start');
exit_form(no_validate);
when dde.dde_param_err then
message('a null value was passed to dde');
exit_form(no_validate);
when dde.dmlerr_notprocessed then
message('a transaction failed');
exit_form(no_validate);
when dde.dmlerr_no_conv_established then
message('no conversation est.');
exit_form(no_validate);
when others then
message('no conversation est.');
set_application_property(cursor_style,'DEFAULT');
END;

hi martin still have this issue please help to resolve
Previous Topic: Calling multiple reports through alert
Next Topic: validate email id
Goto Forum:
  


Current Time: Mon Sep 16 13:05:17 CDT 2024