Error in Translation
Author: gazman
Creation Date: 2/19/2009 11:19 PM
profile picture

gazman

#1
Am getting the following two errors when running code that has been translated from WLD4 using the WealthScript Translator Version 2.19.0.18167:

cs0246(@ 9,7): The type or namespace name 'finantic' could not be found (are you missing a using directive or an assembly reference?)

cs0246(@ 13,19): The type or namespace name 'WealthScriptTL' could not be found (are you missing a using directive or an assembly reference?)

Something go wrong with the installation of Translator?

This is the beginning of the code where the errors occur:

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

DrKoch

#2
A translated script requires the assembly WealthScriptTL.dll.
It must exist in the WL5 installation folder
(usually C:\Program Files\Fidelity Investments\Wealth-Lab Pro 5)

This assembly comes with WSTL and should be installed when WSTL is installed.
profile picture

gazman

#3
Thank u DrKoch. Found the DLL and solved that problem but have other problems now!!

Firstly, the problem was that WL5's default installation folder is MS123 and the WealthScript Translator's default installation folder is Fidelity Investments - made the connection for the DLL reference.

Now have following errors: "error CS0103: the name "GetWeeklyBar" does not exist in the current context."

Have the same error for AllowSymbolSearch, GetExternalSeries and DailyFromWeekly. The WSTL Help file does not mention these as unsupported functions.
profile picture

DrKoch

#4
Well, WSTL is still in beta and the beta doesn't support the "Time Frame" functions - Sorry.

You have to either wait for the next update (release date not fixed yet)
or
translate these functions manually.

profile picture

Eugene

#5
Gary,

QUOTE:
translate these functions manually.


Here's how:
Intraday / Multi-Time Frame | GetIntradayBar and the similar functions
profile picture

gazman

#6
Thanks guys. The link is a great help.

Eugene, are there any suggested manual workarounds for AllowSymbolSearch, GetExternalSeries and DailyFromWeekly?
profile picture

Eugene

#7
AllowSymbolSearch, GetExternalSeries = GetExternalSymbol + its overload in V5

DailyFromWeekly is deprecated in V5. See Time frame functions in the QuickRef and Multi-time frame analysis in the WealthScript Language Guide.
profile picture

tedclimo

#8
None of the 1st 6 WLP 4.5 strategies translated without errors to WLP 5.3. I am a WLD Pascal user for 10ish years, but this .Net is like Chinese.

The good news is that the errors all appear to be related to accessing a specific bar in variois series. Below is a snippet of one Example:

CODE:
Please log in to see this code.


Translated Code gives errors to every reference above involving @C[bar], @MA[bar], @StochDSeries( 3,3)[bar];, @SMASeries(#Close, 10)[bar]

CODE:
Please log in to see this code.


I've read thru dozens of posts & part of Programming guide, but am still stumped. Since I'm new to .Net, please keep it simple. Many of the posts made reference to handles & overloads --- unfamiliar terms in my Pascal experience.

Thanks in advance.
profile picture

Eugene

#9
QUOTE:
but this .Net is like Chinese.

Frankly, this is not pure WealthScript -- after all, you're dealing with a middleman in the face of a wrapper library devoted to make your transition easier. Pure C# is terse.

QUOTE:
reference to handles & overloads --- unfamiliar terms in my Pascal experience.

Handles have always been where - how would we live without handles to price series? Overload is a shortcut for "overloaded method call" - e.g. there is a "BuyAtMarket" call where you specify the signal name, and there is an overloaded call where you can skip it when your signal doesn't have a meaningful name attached. This is overloading in plain English.

Here's the first shot at your code. Note that the order of parameters for StochD has been changed. Compare the WL4 version with the WL5 version - period/smooth became smooth/period.

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

tedclimo

#10
Eugene,
You Rock! I'm not worried about parameters. I just need to learn the .Net syntax well enough so I can troubleshoot my own work & not be too much of a burden to you Wizards,

A greatful Hobbit,

Ted
profile picture

tedclimo

#11
Eugene,

Am pulling my hair out. Just spent last 3 hrs trying to copy & paste your code snippet into my 5.3 strategy that is exhibiting the errors. I cannot insert your code without deleting the entire script & then all your code ends up on line 1. Any idea what I am doing wrong?

All my bread-n-butter is made on just 3 scripts, but all 3 are 'full of errors' after WLP5.3 translation --- to my point ---- does your organization have a service where I can hire Fidelity/Wealth-Lab to convert these private scripts for me offline? Or is there a formal procedure for making a request of this sort? I manage 8 figures at Fidelity and don't want to publish these 3 scripts in order to a get working version(s) on WLP5.3.

Thanks in advance for your assistance.

Ted



profile picture

Eugene

#12
Hi Ted,

QUOTE:
Am pulling my hair out. Just spent last 3 hrs trying to copy & paste your code snippet into my 5.3 strategy that is exhibiting the errors. I cannot insert your code without deleting the entire script & then all your code ends up on line 1. Any idea what I am doing wrong?

Yes: Internet Explorer 7. For some reason, copying/pasting directly from IE7 doesn't work correctly with this forum.

A simple workaround is to copy, paste in Wordpad, copy from Wordpad, and finally paste in WLP.

Or to use Firefox.
QUOTE:
but all 3 are 'full of errors' after WLP5.3 translation

Please create a support ticket.
profile picture

DrKoch

#13
Hi Ted,
I offer the services you mention. You may conatct me via www.finantic.de.
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).