[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[platform-swt-dev] eSWT error when obtaining system image

Apologies if this is the wrong place to ask this question.

The following works fine on windows.

On windows ce I get

Exception in thread "main" java.lang.IllegalArgumentException: Argument not valid
	at org.eclipse.swt.SWT.error(Unknown Source)
	at org.eclipse.swt.SWT.error(Unknown Source)
	at org.eclipse.swt.SWT.error(Unknown Source)
	at org.eclipse.swt.widgets.Widget.error(Unknown Source)
	at org.eclipse.swt.widgets.Label.setImage(Unknown Source)
        at .....

    Display display = new Display();
    Shell shell = new Shell(display);
    shell.setLayout(new FillLayout());
    Label label = new Label(shell,SWT.NONE);
    label.setImage(display.getSystemImage(SWT.ICON_WORKING));
    shell.open();
    while(!shell.isDisposed())
    {
      if (!display.readAndDispatch())
      {
        display.sleep();
      }
    }
    display.dispose();


I created this simple test case. I have loads of other eswt code that works fine on windows ce.

Any ideas?
--
Paul French
Kirona Solutions Ltd
Tel: 07803 122 058
E-Mail: paul.french@xxxxxxxxxx
Web: www.kirona.com

This email and any attachments are confidential and should only be read by those to whom they are addressed. If you are not the intended recipient, please contact us on 01625 585511, delete the email (including any attachment) from your computer and destroy any copies. Any distribution or copying without our prior permission is prohibited. Internet communications are not always secure and may be subject to delays, non-delivery and unauthorised alterations. Therefore, information expressed in this message is not given or endorsed by Kirona Solutions Limited ("Kirona") unless otherwise notified by our duly authorised representative independent of this message. No warranty is given that this email (including any attachment) is virus free. Any views or opinions presented are solely those of the author and do not necessarily represent those of Kirona.

Registered addresses: Kirona Solutions Limited, Barrington House, Heyes Lane, Alderley Edge, Cheshire. SK9 7LA Registered in England and Wales No: 04678711