I have a code that was converted from WL4 to WL6. It references an external series XAO. Code as follows:
XAO = (int)GetExternalSeries("XAO", WL_CLOSE);
And I receive the following error message/s:
error CS1502 @49(49,15) : The best overloaded method match for 'WealthLab.WealthScript.GetExternalSeries(string.WealthLab.DataSeries)' has some invalid agruments
and
error CS1503 @ (49, 40): Argument '2': cannot convert from 'int' to 'WealthLab.DataSeries'
Does anybody know how to fix or work around this? Many thanks in advance.
Jim
Size:
Color:
This question has been raised numerous times since 2008. I'm sure you will find the answer yourself - after carefully searching the WealthScript Translator forum for GetExternalSeries.
Size:
Color:
Size:
Color:
Hello Eugene, Thank you for your response but I had already been through the posts and could not find an answer to my specific question. I tried replacing
CODE:
Please log in to see this code.
with
CODE:
Please log in to see this code.
Then as I am using (well was in WL4) XAO as a filter I had the following converted code
CODE:
Please log in to see this code.
So I replaced this with
First part
CODE:
Please log in to see this code.
and second part
CODE:
Please log in to see this code.
And then I get the following message:
error CS0103 @ (83,27) : The name 'bar' does not exist in the current context
I am not sure what I am doing wrong, but I suspect that it has something to do the with '(int)' in the original GetExternalSeries. Any help would be greatly appreciated, I have looked through the forums long and hard and have not been able to address my specific problem, I suspect that it is something simple but am not sure.
Many thanks in advance.
Jim
Size:
Color:
Size:
Color:
Eugene, many thanks. I take your point with mixing Wealthlab 6 syntax and Translator output, this makes sense. It was just a work around that I was attempting, I should have explained the following which I had tried first:
If I use WealthScript Translator Output and include
DataSeries XAO = GetExternalSymbol("XAO", true).Close;
instead of
XAO = (int)GetExternalSeries("XAO", WL_CLOSE);
It compiles with no errors but when I back-test it on my dataset I get the following message:
'Error processing <insert symbol name> Series Parameter Name: Price Series Handle not defined.
But when I take out of the code all reference to XAO the code runs perfectly and has no problem identifying symbols. I am not sure why when I reference the external reference that Wealthlab can no longer see the data symbols. Is there a simple solution to this? Thanks in advance.
Jim
Size:
Color:
Sorry, I'm not aware of simple solutions to this outdated GetExternalSeries issue. Some scripts are easier to translate manually.
QUOTE:
It compiles with no errors but when I back-test it on my dataset I get the following message:
'Error processing <insert symbol name> Series Parameter Name: Price Series Handle not defined.
No idea without seeing the script. WL6 can't produce this error message, it's thrown out by the unsupported WS Translator, as suggested by the legacy term "Price Series".
Size:
Color:
Hello Eugene, I have now finished reprogamming entire code in "pure C#", much neater than converted code and probably more robust.
Many thanks for your help and pointing me in the right direction.
Jim
Size:
Color:
You're welcome Jim.
Size:
Color:
CODE:
Please log in to see this code.
On a related topic, I would like to use both of the above indexes. What will I need to do to accomplish this? Thanks
Size:
Color:
You're asking in the WealthScript Translator forum.
Since GetExternalSymbol is not GetExternalSeries and being a "new" addition (to Version 5), it has nothing to do with WSTL, please either pick an existing thread in the WealthScript forum among dozens that deal with GetExternalSymbol, or start a new one.
Size:
Color:
Will do. Thanks
Size:
Color: