DDE (EXCEL) Question in Forms 6i
Hello,
I need to open excel for showing some data from one table.
I wanted to do it with DDE (I believed it would be better ??), so I've done this procedure:
PROCEDURE show_excel IS
ConvID PLS_INTEGER;
BEGIN
CONVID:=DDE.Initiate('EXCEL.EXE', 'C:\abc.xls');
END;
but this always have the same answer :
106556 - non-ORACLE exception
how could I open a new worksheet and show the data I want to ??
Thanks.
Hellow Henry,
Please check the following Procedures:
Procedure Launch_Excel IS
appl_name VARCHAR2(255);
BEGIN
IF :GLOBAL.application_id IS NOT NULL THEN
MESSAGE('Application is already running.');
ELSE
appl_name := 'C:\MSOffice\Excel\EXCEL.EXE';
:GLOBAL.application_id := DDE.APP_BEGIN(appl_name, DDE.APP_MODE_NORMAL);
END IF;
EXCEPTION
WHEN DDE.DDE_APP_FAILURE THEN
MESSAGE('Could not launch application for DDE operations.');
RAISE FORM_TRIGGER_FAILURE;
WHEN OTHERS THEN
MESSAGE('Error: '| |TO_CHAR(SQLCODE)| |' '| |SQLERRM);
RAISE FORM_TRIGGER_FAILURE;
END Launch_Excel;
PROCEDURE Open_Channel IS
IF :GLOBAL.channel_id IS NOT NULL THEN
MESSAGE('Communication channel already established.');
ELSIF :GLOBAL.application_id IS NULL THEN
MESSAGE('Application must be launched first.');
ELSE
:GLOBAL.channel_id := DDE.INITIATE('EXCEL', 'BOOK1');
END IF;
EXCEPTION
WHEN DDE.DDE_INIT_FAILED THEN
MESSAGE('Could not initialize DDE communication channel.');
RAISE FORM_TRIGGER_FAILURE;
WHEN DDE.DMLERR_NO_CONV_ESTABLISHED THEN
MESSAGE('Could not establish DDE communication channel.');
RAISE FORM_TRIGGER_FAILURE;
WHEN OTHERS THEN
MESSAGE('Error: '| |TO_CHAR(SQLCODE)| |' '| |SQLERRM);
RAISE FORM_TRIGGER_FAILURE;
END Open_Channel;
Procedure Close_Channel IS
channel_id PLS_INTEGER;
BEGIN
IF :GLOBAL.channel_id IS NULL THEN
MESSAGE('No communication channels are open at this time.');
ELSE
channel_id := TO_NUMBER(:GLOBAL.channel_id);
DDE.TERMINATE(channel_id);
:GLOBAL.channel_id := NULL;
END IF;
EXCEPTION
WHEN OTHERS THEN
MESSAGE('Error: '| |TO_CHAR(SQLCODE)| |' '| |SQLERRM);
RAISE FORM_TRIGGER_FAILURE;
END;
Procedure Close_Excel IS
application_id PLS_INTEGER;
BEGIN
IF :GLOBAL.application_id IS NULL THEN
MESSAGE('Cannot terminate an instance that is not initiated by this application.');
ELSE
application_id := TO_NUMBER(:GLOBAL.application_id);
DDE.APP_FOCUS(application_id);
DDE.APP_END(application_id);
:GLOBAL.application_id := NULL;
:GLOBAL.channel_id := NULL;
END IF;
EXCEPTION
WHEN DDE.DDE_APP_NOT_FOUND THEN
MESSAGE('Could not find application for DDE operations.');
RAISE FORM_TRIGGER_FAILURE;
WHEN OTHERS THEN
MESSAGE('Error: '| |TO_CHAR(SQLCODE)| |' '| |SQLERRM);
RAISE FORM_TRIGGER_FAILURE;
END;
Procedure Exit_Form IS
application_id PLS_INTEGER;
BEGIN
IF :GLOBAL.application_id IS NOT NULL THEN
application_id := TO_NUMBER(:GLOBAL.application_id);
DDE.APP_FOCUS(application_id);
DDE.APP_END(application_id);
END IF;
EXIT_FORM;
EXCEPTION
WHEN DDE.DDE_APP_NOT_FOUND THEN
MESSAGE('Could not find application for DDE operations.');
RAISE FORM_TRIGGER_FAILURE;
WHEN OTHERS THEN
MESSAGE('Error: '| |TO_CHAR(SQLCODE)| |' '| |SQLERRM);
RAISE FORM_TRIGGER_FAILURE;
END Exit_Form;
How To use them:
1-In The First Procedure you have to use the path
of ur own app, ex: Excel.
2-To determine the Path all the time
without troubles use the following
PLL File in
C:\orant\TOOLS\DEVDEM60\DEMO\FORMS
File Name: "D2KWUTIL.PLL"
There are some Functions to read/write
registry.
3-Insert intp "Pre-Form" Trigger:
:GLOBAL.application_id := NULL;
:GLOBAL.channel_id := NULL;
4-Once u have launched App, then
Initiate it, using Open_Channel.
5-When Finished, close both channel
and App. to save resources.
6-Excel Registry Entry is at:
HKEY_LOCAL_MACHINE
|_Software
|_Microsoft
|_Office
|_9.0 --> (for Office 2k)
|_Excel
|_InstallRoot
Look for the Entry "Path".
7-Proc "Exit_Form" isa provided to check if
the Excelinstance is opened by ur app.
And That's It.
However, I do not Recommen d using DDE,
instead u may use "Com Automation".
Hope this Helps,
Tariq
null
Similar Messages
-
Help read excel path from forms 4.5
i have trigger on when-button-pressed which opens excel file whit HOST like
host('"C:\Program Files\Microsoft Office\OFFICE11\excel.exe" '||cFileName);
My question is: How to read excel path from forms 4.5 whitout any utility or extra pll, because excel.exe is not always on path C:\Program Files\Microsoft Office\OFFICE11
thanksStoring the path of excel in some kind of file or db-table is not a good solution, for this may change with any version of excel.
Let the operating system decide on its on, just call
HOST('rundll32.exe url.dll, FileProtocolHandler "' || vcFile || '"');
where vcFile is the file you want to open -
DDE OR OLE2 IN FORM WEB APPLICATIONS
I wonder to know whether it is possible to use ole2 and dde
functions in web form application. In two-tiers client\server
application, user can invoke an application, like Excel or word,
by using DDE or OLE2 package. When it comes to three-tiers,
client\form server(application server)\ db server, if I still
want to have dde or ole2 function to just invoke an application
to view files that are located in network drive or speified
local file name, can forms designed with forms45 do this in web
application? If it can done,what can kind of set is needed in
the application server or client side?
I will greatly apprecicate someone can give some comment on this
matter. Do I have to find another way to have this function in
form web application environment?
Thanks in advance.
Mike
nullJava EE is for enterprise level development, which i imagine would be rather large business applications.
JSE with JMF is sufficient for writing a video chat application.
[http://java.sun.com/javase/technologies/desktop/media/jmf/] -
Unable to import the excel template into form in HFM
Has any one came across this issue that I am facing now?
I have a form in HFM and I exported the form to Excel and the export works fine. but when I import the excel template into form, it was not successful. I have 250 rows in the template. I deleted 50 rows and tried to import and it worked fine . Is there any row limit on this?
Below here is the error message that I am getting
An error occured. Please contact your administrator
Error Number: - 2147467259
Error Description:007~Unexpected error~The function returned |.
Error SOrce: request Object
Page on which error occured:/hfm/data/processImportWdeffromExcel.asp
I appreciate any ideas on thisWhat version of HFM and Excel?
Make sure you honor the file extension requirements for 2007 docs and import the same as they are exported. -
Upload Excel to a form in Oracle Applications: 11.5.10.2
Hi
I want to upload excel into a form in Oracle 11i application - order management. There are two columns in Excel Delivery number and Delivery Date. Search each delivery number in Shipping>Transaction>Query Manager . Go to Date field and copy respective Delivery date. Please let me know how to do this using a Macro. I cannot use SQL loader for this. Also I do not have access to server apps.
Regards
SinduPlease see this thread (applicable to 11i).
How to download spreadsheets to the EBS R12 database
How to download spreadsheets to the EBS R12 database
Thanks,
Hussein -
Please verify my account. I have an excel question I'm working on today. Thank you.
Should happen automatically or you can also add your request in this thread.
https://social.msdn.microsoft.com/Forums/en-US/fb60847b-188f-4075-93d0-3438e06d9047/verify-your-account-22?forum=reportabug
Regards, Dave Patrick ....
Microsoft Certified Professional
Microsoft MVP [Windows]
Disclaimer: This posting is provided "AS IS" with no warranties or guarantees , and confers no rights. -
Running JSP Excel report from Forms 10g
Perhaps this had been discussed before, though I didn't find an exact solution.
We have a JSP report that displays data in MS Excel. Works fine if called from the url.
The report shall be called from the form passing a parameter list with PARAMFORM=NO.
Problem: reports runs as designed but opens up an empty Excel spreadsheet. No errors, no data..
We are using RUN_REPORT_OBJECT with desformat=spreadsheet and paramform=no.
We can't use just web.show_document alone since quite a few parameters need to be passed.
I've read in one of the posts that a paper layout need to be created (in addition to web layout) to run RUN_REPORT_OBJECT. We've done that, but now it does not open EXCEL, and displays paper layout in a browser.
So, how to call JSP (Excel) report from Forms passing parameter list without displaying the parameter form?
Thank youWhat is the complete Application Server version you are using? Be sure you are using 10.1.2.2
What platform and version is it installed?
What version of Excel is installed on the client?
Does it work if you use an RDF report?
Try this:
o Change DESFORMAT to DELIMITED
o Append the following to the end of the URL created in the WEB.SHOW call:
&mimetype=application/vnd.ms-excel
The result should be the same as using SPREADSHEET. -
Excel question--appropriate here? If not, where?
Is there an appropriate place in these fora to ask a simple Excel question?
In any case, here it is:
(iMac G5 1.6MHz, running 10.4.10)
After some Tiger version update about a year ago, the tops of my Excel X worksheets default-opened and zoomed behind the status and formula bars. In other words, when I open a new worksheet or click on the green zoom button, the worksheet aligns itself so that the title bar and the column heads hide behind the status and formula bars. I recently upgraded to Excel 2004 hoping that the problem would fix itself. Nope.
Sorry if this is posted in the wrong place...
iMac G5; iBook G4; Mac Mini G4 Mac OS X (10.4.10)I always had a hard time with MS help and found google groups to be quite good.
http://groups.google.com/group/microsoft.public.mac.office.excel/topics?lnk=sg&h l=en
This link is to Microsoft.public.mac.office.excel
Good luck, Glynn
I Have 2004 and have not had this problem. -
Using DDE to create an Excel spreadsheet from forms
I'm able to write text to the sheet, but I've not been able to find a way to automatically set the width of the columns based on my data. It would be a big help if someone could even just point me to the correct manual to read.
Thanks,
RonOLE2 Package similar to client_ole2He didn't talk a bout an OLE2-package similar to client_ole2. He talked abouit THE OLE2-package (which in fact is the same which is called "behind the scene" in client_ole)
If your OAS is located on a windows-machine, you can use the standard-OLe"-package from forms. But, for that, all operations are executed on the server. So, if for example you do OLE-operations on excel, excel will be started on the server. WIth that, there will be no choice for a user to "interact" when something goes wrong and there are some Excel-fragment snot correctly closed. So, i would be cautious to use this, especialy if you have a lot of users. -
Getting Excel data from forms 6i
Hi Andrew,
I am a good looking woman, could you please send me the routine or .fmb file which performs the reading and writing of data through forms 6i as you discussed on that forum.
I will really appreciate if you can send this to my email address.
[email protected]
Have a nice day.
Malanhi
don't mind why u write u r a good looking woman. u just poet ur question. this is education fouram ok .just pur ur question ..
ur answer is
DECLARE
APPID PLS_INTEGER;
CONVID PLS_INTEGER;
x number:=1;
BEGIN
APPID := DDE.APP_BEGIN('C:\Program Files\Microsoft Office\Office10\excel.exe',dde.app_mode_normal);
CONVID := DDE.INITIATE('EXCEL','system');
DDE.EXECUTE(CONVID,'[Save.as("c:\test1.xls",1)]',10000);
DDE.TERMINATE(CONVID);
CONVID := DDE.INITIATE('EXCEL','c:\test1.xls');
go_block('dept');
first_record;
loop
go_item('deptno');
for y in 1..3 loop
DDE.POKE(CONVID,'R'||x||'C'||y,ltrim(rtrim(:system.cursor_value)),DDE.CF_TEXT,1000);
next_item;
end loop;
x:=x+1;
next_record;
end loop;
DDE.EXECUTE(CONVID,'[Save()]',10000);
DDE.TERMINATE(CONVID);
DDE.APP_END(APPID);
exception
when others then
DDE.EXECUTE(CONVID,'[Save()]',10000);
DDE.TERMINATE(CONVID);
DDE.APP_END(APPID);
END;
write code when-button-pressed trigger
Rizwan
[email protected] -
New user with several questions on forms and useage.
Once a user fills out a form, is there a way to make the data in the text fields un-editable?
While I'm here, on the same form there are several fields that are required to be filled out. Is it possible to prevent the user from being able to save the form before they fill out the required fields?
I have an Excel file that when opened asks the user for certain data and automatically puts the entered data into the required cells using VB. Is it possible to do the same in Adobe?
Been using Acrobat for years, but my company only uses it for simple pdf creation and maybe putting stamps on customer supplied files, so these probably seem like simple questions.
By the way this is on Acrobat 8 Pro.
Thanks for any help!Once a user fills out a form, is there a way to make the data in the text fields un-editable?
Yes. The best is by using a digital signature. Second best is by using a script to set the fields as read-only at some point.
Is it possible to prevent the user from being able to save the form before they fill out the required fields?
No. You can set fields as required but that only applies when the file is submitted. You can display an error message when the file is being saved if some of the required scripts are not filled-in (using a script), but you can't prevent someone from saving the file.
I have an Excel file that when opened asks the user for certain data and automatically puts the entered data into the required cells using VB. Is it possible to do the same in Adobe?
Yes, that's possible. Again, using a script.
By the way this is on Acrobat 8 Pro.
This is quite an old version, not compatible with any current operating system. You should consider upgrading... -
Guys,
I am working on OLE excel to download data from SAP.I have few basic questions for OLE excel
1. I want to merge Cells in EXCEL , how can i do it?
2. I want to make alignment right in some Cell,how can i do it?
3. I have been reading post in SDN for OLE ,so in that one i notice different numbers for colors like
SET PROPERTY OF O_INTERIOR 'Color' = '10092543'.
.how can i know the code for color. as well as for alignment of text in cell .
SET PROPERTY OF O_CELL 'HorizontalAlignment' = -4108 .
..so from where do you know -4180 is for center alignment
4. How can i know different methods and properties of excel cell as well as workbook.
I know these are lot of questions,but basic ones i guess.If someone can give me guidance that would be helpful and points will be given.Suppose EXCEL is your EXCEL.APPLICATION handler
All H_ objects are of TYPE OLE2_OBJECT type
1. for merging
data:
H_RANGE TYPE OLE2_OBJECT,
H_MERGE TYPE OLE2_OBJECT.
CALL METHOD OF EXCEL 'Range' = H_RANGE
EXPORTING
#1 = 'A10'
#2 = 'K10'.
CALL METHOD OF H_RANGE 'Merge' = H_MERGE .
2. for aligning, row and col are of type i.. referring to the cell you wish to change
1 = default
2 = left
3 = center
4 = right
5 = justify
CALL METHOD OF EXCEL 'Cells' = H_CELL
EXPORTING
#1 = ROW
#2 = COL.
SET PROPERTY OF h_cell 'HorizontalAlignment' = 3.
3. For color coding see this program
*& Report ZKRIS_OLE3_PALETTE
*& Displays the full OLE color range in excel
REPORT ZKRIS_OLE3_PALETTE.
TYPE-POOLS ole2 .
DATA: count TYPE i,
count_real TYPE i,
application TYPE ole2_object,
workbook TYPE ole2_object,
excel TYPE ole2_object,
sheet TYPE ole2_object,
cells TYPE ole2_object.
CONSTANTS: row_max TYPE i VALUE 256.
DATA index TYPE i.
DATA:
h_cell TYPE ole2_object, " cell
h_f TYPE ole2_object, " font
h_int TYPE ole2_object,
h_width TYPE ole2_object,
h_columns TYPE ole2_object,
h_rows TYPE ole2_object,
h_font TYPE ole2_object,
h_entirecol TYPE ole2_object.
DATA: h_range TYPE ole2_object.
DATA: h_merge TYPE ole2_object.
CREATE OBJECT excel 'EXCEL.APPLICATION'.
IF sy-subrc NE 0.
WRITE: / 'No EXCEL creation possible'.
STOP.
ENDIF.
SET PROPERTY OF excel 'DisplayAlerts' = 0.
CALL METHOD OF excel 'WORKBOOKS' = workbook .
SET PROPERTY OF excel 'VISIBLE' = 1.
* creating workbook
SET PROPERTY OF excel 'SheetsInNewWorkbook' = 1.
CALL METHOD OF workbook 'ADD'.
CALL METHOD OF excel 'WORKSHEETS' = sheet
EXPORTING
#1 = 1.
SET PROPERTY OF sheet 'NAME' = 'Color Palette'.
CALL METHOD OF sheet 'ACTIVATE'.
DATA: col TYPE i VALUE 1,
row TYPE i VALUE 2,
col1 TYPE i VALUE 2,
col_real TYPE i VALUE 1.
row = 1.
col = 3.
CALL METHOD OF excel 'Cells' = h_cell
EXPORTING
#1 = row
#2 = col.
SET PROPERTY OF h_cell 'Value' = 'No.'.
col = col + 1.
CALL METHOD OF excel 'Cells' = h_cell
EXPORTING
#1 = row
#2 = col.
SET PROPERTY OF h_cell 'Value' = 'Background'.
col = col + 1.
CALL METHOD OF excel 'Cells' = h_cell
EXPORTING
#1 = row
#2 = col.
SET PROPERTY OF h_cell 'Value' = 'Foreground with white background'.
col = col + 1.
CALL METHOD OF excel 'Cells' = h_cell
EXPORTING
#1 = row
#2 = col.
SET PROPERTY OF h_cell 'Value' = 'Foreground with black background'.
CALL METHOD OF excel 'Rows' = h_rows
EXPORTING
#1 = '2:2'.
SET PROPERTY OF h_rows 'WrapText' = 1.
col = 9.
CALL METHOD OF excel 'Cells' = h_cell
EXPORTING
#1 = row
#2 = col.
SET PROPERTY OF h_cell 'Value' = 'No.'.
col = col + 1.
CALL METHOD OF excel 'Cells' = h_cell
EXPORTING
#1 = row
#2 = col.
SET PROPERTY OF h_cell 'Value' = 'Background'.
col = col + 1.
CALL METHOD OF excel 'Cells' = h_cell
EXPORTING
#1 = row
#2 = col.
SET PROPERTY OF h_cell 'Value' = 'Foreground with white background'.
SET PROPERTY OF h_cell 'Bold' = 1.
col = col + 1.
CALL METHOD OF excel 'Cells' = h_cell
EXPORTING
#1 = row
#2 = col.
SET PROPERTY OF h_cell 'Value' = 'Foreground with black background'.
CALL METHOD OF excel 'Rows' = h_rows
EXPORTING
#1 = '1:1'.
SET PROPERTY OF h_rows 'WrapText' = 1.
GET PROPERTY OF h_rows 'Font' = h_font.
SET PROPERTY OF h_font 'Bold' = 1.
count = 1.
count_real = count.
row = 2.
col = 3.
DO 56 TIMES.
PERFORM write_num_and_color.
ENDDO.
* autofit
CALL METHOD OF excel 'Columns' = h_columns
EXPORTING
#1 = 'C:L'.
GET PROPERTY OF h_columns 'EntireColumn' = h_entirecol.
SET PROPERTY OF h_entirecol 'Autofit' = 1.
* write palette on lhs
*range
CALL METHOD OF excel 'Range' = h_range
EXPORTING
#1 = 'A2'
#2 = 'A20'.
CALL METHOD OF h_range 'Merge' = h_merge .
CALL METHOD OF excel 'Cells' = h_cell
EXPORTING
#1 = 2
#2 = 1.
SET PROPERTY OF h_cell 'Value' = 'Palette'.
SET PROPERTY OF h_cell 'Orientation' = 90. "angled.
SET PROPERTY OF h_cell 'HorizontalAlignment' = 3. "center align
GET PROPERTY OF h_cell 'Font' = h_f.
SET PROPERTY OF h_f 'Bold' = 1. "bold
SET PROPERTY OF h_f 'Name' = 'Comic Sans MS'.
SET PROPERTY OF h_f 'Size' = '14'.
SET PROPERTY OF h_cell 'VerticalAlignment' = 2. "center align
* autofit
CALL METHOD OF excel 'Columns' = h_columns
EXPORTING
#1 = 'A:A'.
GET PROPERTY OF h_columns 'EntireColumn' = h_entirecol.
SET PROPERTY OF h_columns 'ColumnWidth' = 4.
*& Form write_num_and_color
* text
FORM write_num_and_color.
index = row_max * ( row - 1 ) + col.
CALL METHOD OF sheet 'Cells' = cells
EXPORTING
#1 = index.
SET PROPERTY OF cells 'Value' = count_real.
col = col + 1.
CALL METHOD OF excel 'Cells' = h_cell
EXPORTING
#1 = row
#2 = col.
GET PROPERTY OF h_cell 'Interior' = h_int.
SET PROPERTY OF h_int 'ColorIndex' = count_real.
col = col + 1.
CALL METHOD OF excel 'Cells' = h_cell
EXPORTING
#1 = row
#2 = col.
SET PROPERTY OF h_cell 'Value' = 'Sample Text'.
GET PROPERTY OF h_cell 'Font' = h_f.
SET PROPERTY OF h_f 'ColorIndex' = count_real.
col = col + 1.
CALL METHOD OF excel 'Cells' = h_cell
EXPORTING
#1 = row
#2 = col.
GET PROPERTY OF h_cell 'Interior' = h_int.
SET PROPERTY OF h_int 'ColorIndex' = 1.
SET PROPERTY OF h_cell 'Value' = 'Sample Text'.
GET PROPERTY OF h_cell 'Font' = h_f.
SET PROPERTY OF h_f 'ColorIndex' = count_real.
row = row + 1.
col = col - 3.
count = count + 1.
IF count = 29.
count = 1.
row = 2.
col = col + 6.
ENDIF.
count_real = count_real + 1.
ENDFORM. "write_num_and_color
4. To know the different OLE properties, you need to examine the macros in excel and then use a bit of trial and error at first -
Sending data to EXCEL from Oracle Forms 6.0 URGENT!!!!!
Dear all,
I have a problem to which I hope to get a solution from anyone
out there...
The problem is as follows:
I have a form that contains some data. Now this data I need to
transfer to an excell sheet. I tried to do so through report
builder (6.0) but every time I try to convert my report I get a
general protection fault. So instead I'm sending the data to a
text file through text_io built in then reopening the text file
from excel. Isn't there a better way to do it? ie sending the
data stright from forms to excel?
Thanks in advance
nullTRY THIS OUT....OLE2.... IT WORKS GREAT...DIRECTLY TO EXCEL...
Oracle Corporate Support
Problem Repository
1. Prob# 1030046.6 NEW: OLE AUTOMATION NO LONGER WORKS AFTER
UPGRADE TO OF
2. Soln# 2077481.6 NEW: MICROSOFT CHANGED OLE INTERFACE FOR
OFFICE97
1. Prob# 1030046.6 NEW: OLE AUTOMATION NO LONGER WORKS AFTER
UPGRADE TO OF
Problem ID : 1030046.6
Affected Platforms : MS Windows 95
MS Windows NT
Affected Products : SQL*Forms
Oracle Reports
Oracle Graphics
Oracle Developer/2000
Affected Components : SF40 V04.05.XX
SQLREP V02.05.XX
ORAGRAPH V02.05.XX
DEV2K Generic
Affected Oracle Vsn : Generic
Summary:
NEW: OLE AUTOMATION NO LONGER WORKS AFTER UPGRADE TO OFFICE97
+=+
Problem Description:
====================
You have upgraded to Microsoft Office97 and OLE calls in your
Developer/2000
applications no longer work.
Problem Explanation:
====================
Examples:
You are using Forms to send data to a Microsoft Word document
and print
letters, using ole automation. This worked fine with Word 6.0,
but when
they
upgraded to Word 8.0 (Office97), the letters do not get printed.
When you try to get an object handle to the Excel97 Workbooks
collection
using
the OLE2 Package, you get the following error:
FRM-40735: WHEN-BUTTON-PRESSED trigger raised unhandled exception
ORA-305500
The Same code works fine against Excel 7.0.
[ Search Words: Office 97 msoffice ms office object linking and
embedding
application get_obj_property workbook invoke_obj
appshow
upgrade upgrading bug483090 olex.rdf demo ]
+==+
Diagnostics and References:
2. Soln# 2077481.6 NEW: MICROSOFT CHANGED OLE INTERFACE FOR
OFFICE97
Solution ID : 2077481.6
For Problem : 1030046.6
Affected Platforms : MS Windows 95
MS Windows NT
Affected Products : SQL*Forms
Oracle Reports
Oracle Graphics
Oracle Developer/2000
Affected Components : SF40 V04.05.XX
SQLREP V02.05.XX
ORAGRAPH V02.05.XX
DEV2K Generic
Affected Oracle Vsn : Generic
Summary:
NEW: MICROSOFT CHANGED OLE INTERFACE FOR OFFICE97
+=+
Solution Description:
=====================
WORD:
Microsoft made some changes in the upgraded version of Word
which cause it
to
come up as a hidden application. Customer had to add "AppShow"
to his code,
and ole automation works fine now.
EXCEL:
The issue here is that Microsoft changed the object "Workbooks",
which is
now
a property of object "Excel.Application". So, replace the call:
workbooks := ole2.invoke_obj(application, 'workbooks');
with
workbooks := ole2.get_obj_property(application, 'workbooks');
For example:
PACKAGE BODY olewrap IS
-- Declare the OLE objects
application OLE2.OBJ_TYPE;
workbooks OLE2.OBJ_TYPE;
workbook OLE2.OBJ_TYPE;
worksheets OLE2.OBJ_TYPE;
worksheet OLE2.OBJ_TYPE;
cell OLE2.OBJ_TYPE;
args OLE2.LIST_TYPE;
procedure init is
begin
-- Start Excel and make it visible
application := OLE2.CREATE_OBJ('Excel.Application');
ole2.set_property(application,'Visible', 'True');
workbooks := OLE2.GET_OBJ_PROPERTY(application, 'Workbooks');
args:=OLE2.CREATE_ARGLIST;
OLE2.ADD_ARG(args, 'c:\test\ms\excel\test.xls');
workbook := OLE2.GET_OBJ_PROPERTY(workbooks, 'Open', args);
OLE2.DESTROY_ARGLIST(args);
worksheets := OLE2.GET_OBJ_PROPERTY(workbook, 'Worksheets');
worksheet := OLE2.GET_OBJ_PROPERTY(worksheets,'Add');
-- Return object handle to cell A1 on the new Worksheet
args:=OLE2.CREATE_ARGLIST;
OLE2.ADD_ARG(args, 1);
OLE2.ADD_ARG(args, 1);
cell:=OLE2.GET_OBJ_PROPERTY(worksheet, 'Cells', args);
OLE2.DESTROY_ARGLIST(args);
-- Set the contents of the cell to 'Hello Excel!'
OLE2.SET_PROPERTY(cell, 'Value', 'Hello Excel!');
END;
procedure addstuff is
BEGIN
-- Return object handle to cell A1 on the new Worksheet
args := OLE2.CREATE_ARGLIST;
OLE2.ADD_ARG(args, 2);
OLE2.ADD_ARG(args, 2);
cell:=OLE2.INVOKE_OBJ(worksheet, 'Cells', args);
OLE2.DESTROY_ARGLIST(args);
-- Set the contents of the cell to 'This is the added stuff'
OLE2.SET_PROPERTY(cell, 'Value', 'This is the added stuff');
END;
procedure stop is
begin
-- Release the OLE objects
args:=OLE2.CREATE_ARGLIST;
OLE2.ADD_ARG(args, 'C:\OLETEST2.XLS');
OLE2.INVOKE(worksheet, 'SaveAs', args);
OLE2.DESTROY_ARGLIST(args);
OLE2.RELEASE_OBJ(cell);
OLE2.RELEASE_OBJ(worksheet);
OLE2.RELEASE_OBJ(worksheets);
OLE2.RELEASE_OBJ(workbook);
OLE2.RELEASE_OBJ(workbooks);
OLE2.RELEASE_OBJ(application);
END;
Solution Explanation:
=====================
Microsoft changed some of the OLE calling interfaces for the
Office97
products. Thus, some of your existing OLE calls may need to be
changed to
comply with the Office97 interface.
Consult with Microsoft and your Office97 documentation or more
information
on
what the OLE interface is for the Office97 suite of products.
Additional Information:
=======================
Related Bugs:
483090 (Closed, Vendor OS Problem)
FORM GIVES FRM-40735: UNHANDLED EXCEPTION ORA-305500 AGAINST
EXCEL97.OFMPE0497
+==+
References:
ref: {8192.4} BUG-483090
Oracle Corporate Support
Problem Repository
1. Prob# 1030046.6 NEW: OLE AUTOMATION NO LONGER WORKS AFTER
UPGRADE TO OF
2. Soln# 2077481.6 NEW: MICROSOFT CHANGED OLE INTERFACE FOR
OFFICE97
1. Prob# 1030046.6 NEW: OLE AUTOMATION NO LONGER WORKS AFTER
UPGRADE TO OF
Problem ID : 1030046.6
Affected Platforms : MS Windows 95
MS Windows NT
Affected Products : SQL*Forms
Oracle Reports
Oracle Graphics
Oracle Developer/2000
Affected Components : SF40 V04.05.XX
SQLREP V02.05.XX
ORAGRAPH V02.05.XX
DEV2K Generic
Affected Oracle Vsn : Generic
Summary:
NEW: OLE AUTOMATION NO LONGER WORKS AFTER UPGRADE TO OFFICE97
+=+
Problem Description:
====================
You have upgraded to Microsoft Office97 and OLE calls in your
Developer/2000
applications no longer work.
Problem Explanation:
====================
Examples:
You are using Forms to send data to a Microsoft Word document
and print
letters, using ole automation. This worked fine with Word 6.0,
but when
they
upgraded to Word 8.0 (Office97), the letters do not get printed.
When you try to get an object handle to the Excel97 Workbooks
collection
using
the OLE2 Package, you get the following error:
FRM-40735: WHEN-BUTTON-PRESSED trigger raised unhandled exception
ORA-305500
The Same code works fine against Excel 7.0.
[ Search Words: Office 97 msoffice ms office object linking and
embedding
application get_obj_property workbook invoke_obj
appshow
upgrade upgrading bug483090 olex.rdf demo ]
+==+
Diagnostics and References:
2. Soln# 2077481.6 NEW: MICROSOFT CHANGED OLE INTERFACE FOR
OFFICE97
Solution ID : 2077481.6
For Problem : 1030046.6
Affected Platforms : MS Windows 95
MS Windows NT
Affected Products : SQL*Forms
Oracle Reports
Oracle Graphics
Oracle Developer/2000
Affected Components : SF40 V04.05.XX
SQLREP V02.05.XX
ORAGRAPH V02.05.XX
DEV2K Generic
Affected Oracle Vsn : Generic
Summary:
NEW: MICROSOFT CHANGED OLE INTERFACE FOR OFFICE97
+=+
Solution Description:
=====================
WORD:
Microsoft made some changes in the upgraded version of Word
which cause it
to
come up as a hidden application. Customer had to add "AppShow"
to his code,
and ole automation works fine now.
EXCEL:
The issue here is that Microsoft changed the object "Workbooks",
which is
now
a property of object "Excel.Application". So, replace the call:
workbooks := ole2.invoke_obj(application, 'workbooks');
with
workbooks := ole2.get_obj_property(application, 'workbooks');
For example:
PACKAGE BODY olewrap IS
-- Declare the OLE objects
application OLE2.OBJ_TYPE;
workbooks OLE2.OBJ_TYPE;
workbook OLE2.OBJ_TYPE;
worksheets OLE2.OBJ_TYPE;
worksheet OLE2.OBJ_TYPE;
cell OLE2.OBJ_TYPE;
args OLE2.LIST_TYPE;
procedure init is
begin
-- Start Excel and make it visible
application := OLE2.CREATE_OBJ('Excel.Application');
ole2.set_property(application,'Visible', 'True');
workbooks := OLE2.GET_OBJ_PROPERTY(application, 'Workbooks');
args:=OLE2.CREATE_ARGLIST;
OLE2.ADD_ARG(args, 'c:\test\ms\excel\test.xls');
workbook := OLE2.GET_OBJ_PROPERTY(workbooks, 'Open', args);
OLE2.DESTROY_ARGLIST(args);
worksheets := OLE2.GET_OBJ_PROPERTY(workbook, 'Worksheets');
worksheet := OLE2.GET_OBJ_PROPERTY(worksheets,'Add');
-- Return object handle to cell A1 on the new Worksheet
args:=OLE2.CREATE_ARGLIST;
OLE2.ADD_ARG(args, 1);
OLE2.ADD_ARG(args, 1);
cell:=OLE2.GET_OBJ_PROPERTY(worksheet, 'Cells', args);
OLE2.DESTROY_ARGLIST(args);
-- Set the contents of the cell to 'Hello Excel!'
OLE2.SET_PROPERTY(cell, 'Value', 'Hello Excel!');
END;
procedure addstuff is
BEGIN
-- Return object handle to cell A1 on the new Worksheet
args := OLE2.CREATE_ARGLIST;
OLE2.ADD_ARG(args, 2);
OLE2.ADD_ARG(args, 2);
cell:=OLE2.INVOKE_OBJ(worksheet, 'Cells', args);
OLE2.DESTROY_ARGLIST(args);
-- Set the contents of the cell to 'This is the added stuff'
OLE2.SET_PROPERTY(cell, 'Value', 'This is the added stuff');
END;
procedure stop is
begin
-- Release the OLE objects
args:=OLE2.CREATE_ARGLIST;
OLE2.ADD_ARG(args, 'C:\OLETEST2.XLS');
OLE2.INVOKE(worksheet, 'SaveAs', args);
OLE2.DESTROY_ARGLIST(args);
OLE2.RELEASE_OBJ(cell);
OLE2.RELEASE_OBJ(worksheet);
OLE2.RELEASE_OBJ(worksheets);
OLE2.RELEASE_OBJ(workbook);
OLE2.RELEASE_OBJ(workbooks);
OLE2.RELEASE_OBJ(application);
END;
Solution Explanation:
=====================
Microsoft changed some of the OLE calling interfaces for the
Office97
products. Thus, some of your existing OLE calls may need to be
changed to
comply with the Office97 interface.
Consult with Microsoft and your Office97 documentation or more
information
on
what the OLE interface is for the Office97 suite of products.
Additional Information:
=======================
Related Bugs:
483090 (Closed, Vendor OS Problem)
FORM GIVES FRM-40735: UNHANDLED EXCEPTION ORA-305500 AGAINST
EXCEL97.OFMPE0497
+==+
References:
ref: {8192.4} BUG-483090
null -
Upload the data from excel sheet to form 6i
hi all,
i am using Forms [32 Bit] Version 6.0.8.24.1 (Production)
my requirement is to import data from excel to forms.
i have gone through the help, they have mentioned as below
To build this demo:
1 Create a spreadsheet containing the initial data and formulae that you want to appear in your form.
2 In the Layout Editor, click the OLE container tool and drag out the area where you want to display the spreadsheet.
3 From the pop-up menu on the OLE container, click Insert Object.
4 Click Create from File. Enter the name of the spreadsheet. Click OK.
5 In the Object Navigator, attach the library EXCEL.PLL.
6 To get the value of a cell, call the function GETCELL from the SPREADSHEET package contained in the EXCEL library.
To get the value of a cell, call the procedure SETCELL from the same package.
7 To add other interactions with the spreadsheet, use the OLE2 built-in package. Consult the Excel documentation
for details of Excel’s object model.but if anybody explain this with sample then it will be useful for me..This is first time i am comming such type of requirement across.
Thanks..hi,
i have some sample code(taken from some source)
DECLARE
application ole2.obj_type;
workbooks ole2.obj_type;
workbook ole2.obj_type;
args ole2.list_type;
worksheets OLE2.OBJ_TYPE;
worksheet OLE2.OBJ_TYPE;
BEGIN
application:=ole2.create_obj('Excel.Application');
ole2.set_property(application, 'Visible', 'True');
workbooks := OLE2.GET_OBJ_PROPERTY(application, 'workbooks');
args:=ole2.create_arglist;
ole2.add_arg(args, 'FILE_NAME');
workbook:= ole2.invoke_obj(workbooks, 'Open',args);
ole2.destroy_arglist(args);
args:=ole2.create_arglist;
ole2.add_arg(args, 'c:\Pasta1!teste'); --how to pass the arguments
ole2.invoke(application, 'Run', args);
ole2.destroy_arglist(args);
ole2.release_obj(workbook);
ole2.release_obj(workbooks);
ole2.release_obj(application);
END; but i don't know how to pass the arguments(i have to pass the excell cell values(data)as an arguments)
Suggest me to proceed further..
Thanks..
Edited by: user13329002 on Nov 13, 2010 1:16 AM -
Follow-up question about forms and SharePoint Online
I asked a question about life after InfoPath earlier, and got a good answer:
http://social.technet.microsoft.com/Forums/sharepoint/en-US/fb23b3d9-8a09-4267-aab5-09929f6a3082/life-after-infopath-seeking-advice
After looking at all of the limitations of SharePoint Online, I'm wondering how developers are dealing with the limitations. Lets say you are asked to develop something that has complex logic, including fetching data from external web services, dynamically
displaying parts of a process to people depending on role, and ending up with a printable document. In our on-premises environment, InfoPath is well suited to this task, with some code behind for some things. Or, if not using InfoPath, we would use application
pages and workflow.
Neither of those are available in SharePoint Online, so what would you do?Some things, such as the conditional display of content, can be done via JavaScript. More advanced items, such as integrating external web services would likely require a SharePoint "app". A SharePoint app is essentially a link to a separate site
that is running an asp.net web app (or PHP, or whatever). This asp.net site can do anything it needs with any web services, or conditional formatting, or anything. Because it's registered as a SharePoint app, it can also call back into the SharePoint site
and work with data. So, a SharePoint App could present the user with a robust form that simply sends the data back to a SharePoint list. The SharePoint app can also be surfaced on the SharePoint site itself in an iframe, so the user won't know that the form
is hosted by another server.
By the way, the ideas behind the app model permeate the entire SharePoint environment: instead of having the SharePoint server itself run all kinds of custom business logic, that workload is handled by other servers, so the SharePoint servers can be focused
on running the core bits of SharePoint. InfoPath puts a large load on the servers, so it's out. XSLT list views also put a load on the server, so they're also out. SSRS is an amazingly fantastic tool, but is not supported in the cloud (and there's no
alternative). Timer jobs, event handlers, workflow, and many other things have been re-architected to take the load off the SharePoint servers.
Mike G.
Maybe you are looking for
-
Hi All, I am using Receiver Mail Adapter to send mails. When i choose Message Protocol the mail goes. But when i change it to XIPAYLOAD the mail doesnt go. I cannot find any errors in SXI_MONITOR or in adapter monitoring. My file is in this format..
-
Writing from a BLOB to a FIle on the Server
I need to be able to save the data from a BLOB column to an external file on the server, preferably in a temporary directory. Afterwards I will add a header to the file and send to the web client. I believe I know how to add the header. However, ever
-
i cant receive imessage vis my mobile number ...i can thru my email....i did everything possible .
-
Extreme slow upload speed in Dallas area
Hello Something happened to my upload speed last Thursday, it has dropped considerably connecting to most servers making many sites very sluggish. I have the hardest time just attaching a file in Gmail and the gmail chat keeps saying 'unable to conne
-
Iphone 4 when updated to 6.1.2 wont play video on kenwood in car
When I updated my iphone 4 to the 6.1.2 software it wont play the video in my car anymore. The sound still works but no video, I dont know what happened. I have gone through the kenwood forums and they are saying that it had something to do with the