OmniTrader Professional Forum OmniTrader Professional Forum
forums calendars search
today this week
 
register logon control panel Forum Rules
You are currently browsing as a guest.
You should logon to access more features
A Self-Moderated Community - ALL MEMBERS, PLEASE READ!
Vote for Members who contribute the most to your trading, and help us moderate content within the Forums.


  Current location        Thread information  
OmniTrader Professional Forum
OmniLanguage Discussion
omni language parameters and data types
Last Activity 10/5/2024 12:51 AM
1 replies, 1223 viewings

Jump to page : 1
Now viewing page 1 [25 messages per page]
 
back reply
Printer friendly version

^ Top
ProgrammerMike

New User

Posts: 1

Joined: 1/14/2019
Location: Camano Island, WA

User Profile
 
Subject : omni language parameters and data types
Posted : 1/24/2019 5:29 PM
Post #30269

I'm just starting to get into omnilanguage. I've done a fair amount of programming my systems on Think Or Swim (TOS) platform using their scripting language (thinkscript). I'm unable to establish for sure whether certain features that I use in Thinkscript and are listed as VBA features are not available in Omnilanguage. I looked at the Omnitrader Pro manual as well as the help parts of omnitrader for omnilanguage. The references don't explicitly exclude the following but there is no explanation on how to use the features.
1. Does omnilanguage recogignize any type other than integer for #PARAM parameters?
2. Does omnilanguage support select/case?
3. Does omnilanguage support enumerated types?
While there are workarounds for each of these using the integer type and if then else, they tend to be clunky and non-elegant.
Any help would be appreciated.
^ Top
Jim Dean

Sage
2000100010010010010025
Posts: 3433

Joined: 3/13/2006
Location: L'ville, GA

User Profile
 
Subject : RE: omni language parameters and data types
Posted : 1/24/2019 8:30 PM
Post #30271 - In reply to #30269

1. Params default to integer if their default and range specs are integers. If any of those four are floating, Params become single. (You can Dim integer, single, double, string, Boolean, and limited object. The integers are long integers btw (14 sig fig)
2. Does omnilanguage support select/case? Yes - and most of the nuanced dotNet case specs.
3. Does omnilanguage support enumerated types? No - but you can define a constant in a dim using = “string” or = value, etc.

OL’s greatest limitation from a programming standpoint is the inability to declare arrays. Actually, in the underlying dotNET code, all declared variables are arrays which have a one dimensional size equal to the number of bars loaded. But OL is designed to prevent users from accidentally or on purpose referencing the “future” subscripts (ie later bars) of any of those implicit arrays.

[Edited by Jim Dean on 1/24/2019 11:07 PM]

Jump to page : 1
Now viewing page 1 [25 messages per page]
back reply

Legend    Action      Notification  
Administrator
Forum Moderator
Registered User
Unregistered User
E-Mail this thread to a friend
Toggle e-mail notification


Nirvana Systems
For any problems or issues please contact our Webmaster at webmaster@nirvsys.com.