Dukascopy Support Board
http://www.dukascopy.com/swiss/english/forex/jforex/forum/

NullPointerException on OnStart
http://www.dukascopy.com/swiss/english/forex/jforex/forum/viewtopic.php?f=128&t=48349
Page 1 of 1

Author:  thurlow03m [ Fri 16 Nov, 2012, 08:41 ]
Post subject:  NullPointerException on OnStart

Hi, friends:
I am a newbie for the Jforex platform, and just learned to use some example programs from Strategy tutorial. I used Feeds.java file from Strategy Tutorial for the test.
I copy all the codes from this file and makes a new strategy called " Feeds.java" . Compiling is succesful. But when I test it, it won't go through the whole procedure instead of showing the error message like this: 07:06:49 Strategy tester: java.lang.NullPointerException @ feed.Feeds.onStart(Feeds.java:109)
I checked the line 109, it shows this: this.factory = openedChart.getChartObjectFactory(); It seem there is a problem for openning a chart. I always have same problem even in other file :ChartUsage.java. (Compiling is OK but Just couldn't run!).
Could you please tell me how to deal with this problem ?
Thanks.
Thurlow

Attachments:
Feeds.txt [13.63 KiB]
Downloaded 409 times

Author:  API Support [ Fri 16 Nov, 2012, 10:18 ]
Post subject:  Re: NullPointerException on OnStart

This is because you have not opened the respective chart.

  Page 1 of 1