Compile error: Cannot implicitly convert type
Author: kthomazios
Creation Date: 1/8/2014 9:43 PM
profile picture

kthomazios

#1
Dear WL Support

I have looked up 'convert type' issues in this forum but the two posts I found do not help resolve my problem. I'm trying to create two lists from a single dataset, each list built on a specific parameter, say Return On Capital and EarningsYield. I use the FundamentalsRatio data series to compute the values. Then I try to pass them onto the respective pointers so I can add them to their respective lists. That's where I get compile errors.

The variables ReturnOnCapital and EarningsYield have already been declared as 'internal double' earlier in the code.

The compile error message (twice): cannot implicitly convert type 'WealthLab.DataSeries' to 'double'.

CODE:
Please log in to see this code.


Thanks
K
profile picture

Eugene

#2
You're looking to pass a double value, not a DataSeries. Here's how:

CODE:
Please log in to see this code.
profile picture

kthomazios

#3
Thanks very much, that fixed it.
This website uses cookies to improve your experience. We'll assume you're ok with that, but you can opt-out if you wish (Read more).