Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 312410 - [OLE] Plug-in with View (Excel file with chartsheet and worksheet) is not displayed correctly in Eclipse RCP
Summary: [OLE] Plug-in with View (Excel file with chartsheet and worksheet) is not dis...
Status: RESOLVED WORKSFORME
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 3.5   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Felipe Heidrich CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords:
Depends on:
Blocks:
 
Reported: 2010-05-11 08:40 EDT by mo84 CLA
Modified: 2019-09-02 15:06 EDT (History)
0 users

See Also:


Attachments
Plug-In Project with a embedded MS-Excel (7.43 KB, application/x-zip-compressed)
2010-05-11 08:50 EDT, mo84 CLA
no flags Details
image, which shows the bug. (122.27 KB, image/jpeg)
2010-05-11 08:53 EDT, mo84 CLA
no flags Details
image with correctly displayed chart-sheet (118.22 KB, image/jpeg)
2010-05-11 08:57 EDT, mo84 CLA
no flags Details
Excel Template File (14.00 KB, application/vnd.ms-excel)
2010-05-18 05:31 EDT, mo84 CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description mo84 CLA 2010-05-11 08:40:50 EDT
Build Identifier: 20090920-1017

Hi,

I used an "Plug-in with view" to embed Microsoft Excel (2000). This plug-in is integrated into my Eclipse-RCP.

My template will be displayed with its data- and chartsheet. As soon as I click on the chartsheet (worksheet -> chartcheet) - it is displayed, but not correctly. If I change the size of the view, it is displayed correctly (see the pictures).

greetings,

Marc


wrong:
http://img243.imageshack.us/img243/9193/bugolechartsheet.jpg

correct:
http://img88.imageshack.us/img88/3899/bugolechartsheetok.jpg

Reproducible: Always

Steps to Reproduce:
1. Create a simple "Plug-in with view" Project with embedded MS Excel 2000< document, using the OleClientSite object.

2. Run this plug-in as "Eclipse Application or put it into your existing RCP.

3. Open the view. Then they should see the embedded Excel-File.

4. Add an Chart-Sheet. You have a taskbar at the bottom ( in my screenshot with "Diagramm1", "Tabelle1") Right-mouse-click on one item in this bar, then you should see a menu where you can insert a chart-sheet (insert -> chart)
Comment 1 mo84 CLA 2010-05-11 08:50:28 EDT
Created attachment 167908 [details]
Plug-In Project with a embedded MS-Excel
Comment 2 mo84 CLA 2010-05-11 08:53:51 EDT
Created attachment 167910 [details]
image, which shows the bug.
Comment 3 mo84 CLA 2010-05-11 08:57:34 EDT
Created attachment 167911 [details]
image with correctly displayed chart-sheet
Comment 4 mo84 CLA 2010-05-11 11:08:36 EDT
I have tested the following combinations: 

- Eclipse Galileo (Eclipse for RCP/Plug-in Developers)
- Windows 7/XP
- Excel 2000/2003/2007
- Java SE 1.6.0_17-b04 / Java DK 1.6.0_17
Comment 5 Felipe Heidrich CLA 2010-05-17 09:12:33 EDT
This worked for me on XP SP3 + Office 2003

The code you sent will created a empty excel file, I had to enter some data manually in order to create a chart.

Does it matter the type of chart you add ?
Comment 6 mo84 CLA 2010-05-17 09:25:17 EDT
(In reply to comment #5)
> This worked for me on XP SP3 + Office 2003
> 
> The code you sent will created a empty excel file, I had to enter some data
> manually in order to create a chart.
> 
> Does it matter the type of chart you add ?

Yes. I only have the problem when I insert a chart-sheet (not a worksheet with diagram - that´s an difference).
Comment 7 mo84 CLA 2010-05-18 05:31:00 EDT
Created attachment 168880 [details]
Excel Template File
Comment 8 mo84 CLA 2010-05-18 05:35:46 EDT
(In reply to comment #7)
> Created an attachment (id=168880) [details]
> Excel Template File

simple overwrite createPartControl:

	@Override
	public void createPartControl(Composite parent) {
		try {
			OleFrame frame = new OleFrame(parent, SWT.NONE);

			File template = new File("C:\\Mappe1.xls");
			site = new OleClientSite(frame, SWT.NONE, template);
		} catch (SWTError e) {
			System.out.println("Unable to open activeX control");
			return;
		}
	}


...and put the template to you´re C:\ to use the template (includes chartsheet and worksheet).
Comment 9 Felipe Heidrich CLA 2010-05-18 10:12:41 EDT
Works for me,

at the end of createPartControl, try calling:
site.doVerb(OLE.OLEIVERB_INPLACEACTIVATE);
parent.layout();
Comment 10 mo84 CLA 2010-05-18 11:30:05 EDT
does not work for me. Which configuration do u have? (JavaSE, Office, Windows, Eclipse)
Comment 11 Felipe Heidrich CLA 2010-05-18 13:53:41 EDT
(In reply to comment #10)
> does not work for me. Which configuration do u have? (JavaSE, Office, Windows,
> Eclipse)

Office 2003
Eclipse 3.6 RC1
Java IBM  JDK 1.4.2
Windows XP SP 3 English
Comment 12 mo84 CLA 2010-10-14 08:48:06 EDT
Now I´ve testet the following combinations:

error with:
--------------------------

Windows 2000 SP-4
Eclipse 3.5 / 3.6
jre 1.6.0_11 / jdk1.6.0_20
Excel 2000 SP-3

Windows 7
Eclipse 3.5
Excel 2000 SP-3
jdk1.6.0_17



ok, no error with:
--------------

Windows 7
Eclipse 3.5 / 3.6
Excel 2007
jdk1.6.0_20


Is it possible that the error is related to the MS Office Version?
Comment 13 Felipe Heidrich CLA 2010-10-14 09:35:25 EDT
(In reply to comment #12)
> Is it possible that the error is related to the MS Office Version?

Yes
Comment 14 Eclipse Genie CLA 2018-11-18 04:57:58 EST
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.
Comment 15 Lars Vogel CLA 2019-09-02 15:04:50 EDT
This bug has been marked as stalebug a while ago without any further interaction.

If this report is still relevant for the current release, please reopen and remove the stalebug whiteboard flag.
Comment 16 Lars Vogel CLA 2019-09-02 15:06:11 EDT
This bug was marked as stalebug a while ago. Marking as worksforme.

If this report is still relevant for the current release, please reopen and remove the stalebug whiteboard tag.