Dukascopy
 
 
Wiki JStore Search Login

ClassCastException IndicatorController cannot be cast to StrategyController
 Post subject: ClassCastException IndicatorController cannot be cast to StrategyController Post rating: 0   New post Posted: Tue 08 Apr, 2014, 09:06 
User avatar

User rating: 0
Joined: Tue 25 Feb, 2014, 16:16
Posts: 6
java.lang.ClassCastException: com.dukascopy.connector.controller.IndicatorController cannot be cast to com.dukascopy.connector.controller.StrategyController
at com.dukascopy.connector.lib.MQLModule.getStrategyController(MQLModule.java:56)
at com.dukascopy.connector.lib.impl.CommonFunctions.GetTickCount(CommonFunctions.java:57)
at com.dukascopy.connector.engine.MQL4Connector.GetTickCount(MQL4Connector.java:710)
at jforex.converted.SEFC084.start(SEFC084.java:79)
at com.dukascopy.connector.engine.CommonIndicatorImpl.commonCalculate(CommonIndicatorImpl.java:193)
at com.dukascopy.connector.engine.MQL4ConnectorIndicator.calculate(MQL4ConnectorIndicator.java:85)
at com.dukascopy.charts.math.a.a.a(Unknown Source)
at com.dukascopy.charts.math.dataprovider.AbstractDataProvider$e.c(Unknown Source)
at com.dukascopy.charts.math.dataprovider.AbstractDataProvider$e.run(Unknown Source)

Source - decompiled SEFC084


Attachments:
SEFC084.mq4 [3.5 KiB]
Downloaded 70 times
DISCLAIMER: Dukascopy Bank SA's waiver of responsability - Documents, data or information available on this webpage may be posted by third parties without Dukascopy Bank SA being obliged to make any control on their content. Anyone accessing this webpage and downloading or otherwise making use of any document, data or information found on this webpage shall do it on his/her own risks without any recourse against Dukascopy Bank SA in relation thereto or for any consequences arising to him/her or any third party from the use and/or reliance on any document, data or information found on this webpage.
 
 Post subject: Re: ClassCastException IndicatorController cannot be cast to StrategyController Post rating: 0   New post Posted: Tue 06 May, 2014, 14:01 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
The problem is that GetTickCount() function is not supported for indicators in JForex. You should just simply remove invocation of GetTickCount() from your indicator's source code (results of this function calls are never used), recompile and indicator will work fine. In next API release more descriptive error message will be shown for that situation.


 

Jump to:  

  © 1998-2025 Dukascopy® Bank SA
On-line Currency forex trading with Swiss Forex Broker - ECN Forex Brokerage,
Managed Forex Accounts, introducing forex brokers, Currency Forex Data Feed and News
Currency Forex Trading Platform provided on-line by Dukascopy.com