Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Currency conversion thanksgiving present

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Currency conversion thanksgiving present

    Hello to all,

    as a tool for multi currency portfoglio management I worte a tool to get the current exchange rate for currencies. The tool consists of a C# source file and can be included in your NinjaTrader script.
    You can also use the code outside NinjaTrader, but in this case you need to uncomment the Currency enum definition.

    Here an example:


    {
    string from="EUR";
    string to = "USD";
    // also possible: from=Zweistein.CurrencyConversion.ISO(NinjaTrader. Cbi.Currency.Euro);

    decimal eurusd=Zweistein.CurrencyConversion.Cube.Convert(1 .0, from, to);
    // converts 1.0 EUR into USD using the daily ECB fixing price.

    decimal eurusd2=Zweistein.CurrencyConversion.Convert(1.0, from, to);
    // converts 1.0 EUR to USD using the current exchange rate supplied by google.

    }


    have a nice weekend

    Andreas

    Discover top crypto trading apps like Binance for secure, low-fee trading. Access crypto, forex, and more with real-time tools. Avoid scams, start small, and grow profits.
    Attached Files

Latest Posts

Collapse

Topics Statistics Last Post
Started by Geovanny Suaza, 02-11-2026, 06:32 PM
0 responses
649 views
0 likes
Last Post Geovanny Suaza  
Started by Geovanny Suaza, 02-11-2026, 05:51 PM
0 responses
370 views
1 like
Last Post Geovanny Suaza  
Started by Mindset, 02-09-2026, 11:44 AM
0 responses
109 views
0 likes
Last Post Mindset
by Mindset
 
Started by Geovanny Suaza, 02-02-2026, 12:30 PM
0 responses
574 views
1 like
Last Post Geovanny Suaza  
Started by RFrosty, 01-28-2026, 06:49 PM
0 responses
576 views
1 like
Last Post RFrosty
by RFrosty
 
Working...
X