Cannot implicity convert type WealthLab.DataSeries to double
Author: mrsic
Creation Date: 6/23/2018 11:36 AM
profile picture

mrsic

#1
Hi,

i am not a programmer but i give my best.

If i am setting the LastActivePosition.Priority like this. I am getting the error code "Cannot implicity convert type "WealthLab.DataSeries to double.
CODE:
Please log in to see this code.



Solution looks like this and i am not sure if that's okay with logic? I put in "Convert.ToDouble". Could someone check this logic for me please.
CODE:
Please log in to see this code.

profile picture

Eugene

#2
CODE:
Please log in to see this code.
is more than enough. No need in conversion to double of what is already a double.

Actually, it's documented in the WealthScript Programming Guide > DataSeries > Accessing a Single Value from a DataSeries. It's simple. See the QuickRef for what WL expects you to pass on as argument for e.g. Position.Priority, and pass such data type.
profile picture

mrsic

#3
Thanks Eugene.
profile picture

Eugene

#4
Any time.
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).