NexusFi: Find Your Edge


Home Menu

 





Setting INPUT boundaries in MC powerlanguage


Discussion in MultiCharts

Updated
    1. trending_up 1,485 views
    2. thumb_up 0 thanks given
    3. group 2 followers
    1. forum 1 posts
    2. attach_file 0 attachments




 
Search this Thread

Setting INPUT boundaries in MC powerlanguage

  #1 (permalink)
 
Sinatra Fan's Avatar
 Sinatra Fan 
Orlando FL
 
Experience: Intermediate
Platform: MultiCharts, Ninja
Trading: Emini ES
Posts: 66 since May 2019
Thanks Given: 7
Thanks Received: 9

I'm developing a new strat in powerlanguage for MC (not .net). I have two questions:

1) Are there keywords that I can use to provide tips or boundaries/limits for an input variable? For example: Can I have a tip that explains what this input variable is for and the range of values for that variable?

2) Is there a way to prevent the user from entering in a value not permitted or outside of the limits intended for that variable? For example, If entering zero causes the program to error out due to division by zero, then I would want that value not to be entered or allowed.

If yes to these, can you help me out with them. Thanks

Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
My NT8 Volume Profile Split by Asian/Euro/Open
NinjaTrader
New Micros: Ultra 10-Year & Ultra T-Bond -- Live Now
Treasury Notes and Bonds
Futures True Range Report
The Elite Circle
The space time continuum and the dynamics of a financial …
Emini and Emicro Index
NT7 Indicator Script Troubleshooting - Camarilla Pivots
NinjaTrader
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Get funded firms 2023/2024 - Any recommendations or word …
61 thanks
Funded Trader platforms
39 thanks
NexusFi site changelog and issues/problem reporting
26 thanks
Battlestations: Show us your trading desks!
26 thanks
The Program
18 thanks
  #2 (permalink)
 
syswizard's Avatar
 syswizard 
Philadelphia PA
 
Experience: Advanced
Platform: Multicharts
Broker: Ironbeam, Rithmic
Trading: Emini ES / NQ / CL / RTY / YM / BTC
Posts: 344 since Jan 2019
Thanks Given: 20
Thanks Received: 146

Well you can't provide tips for the input, but you could invoke the windows messagebox function to have a pop-up window show when there are invalid inputs.
https://docs.microsoft.com/en-us/windows/win32/api/winuser/nf-winuser-messagebox
You will have to declare the USER32.DLL in the Powerlanguage code:
DefineDLLFunc: "User32.dll
Good luck.

Reply With Quote




Last Updated on April 3, 2021


© 2024 NexusFi™, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
All information is for educational use only and is not investment advice. There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Privacy Policy - Downloads - Top
no new posts