This release candidate will become the official release when no bugs are found in the next time. Please test everything and report any issues here! As usual, if you're the first one to find a new and serious bug in the release candidate, you can get a free Zorro S subscription or support extension. This time the chance is particularly good because we switched to a new compiler and to new versions of many libraries.
Re: New Zorro version 2.50
[Re: jcl]
#486307 07/25/2213:4707/25/2213:47
I had a situation where I was overloading with (BOOL, char*, const char*), so this was an ambiguity error. Either the char* overload should be removed, or two variations with (BOOL, const char*, char*) and (BOOL, char*, const char*) should be added.
Also, if ifelse() is using a const char*, shouldn't it be returning a const char* instead of a char*?
The two overloads cover almost all cases where ifelse is used with Zorro functions or indicators. The second overload returns a char' because it is for arguments of type "string", which convert to const char', but can in fact be passed to functions that accept char*.
We didn't want to inflate zorro.h even more with even more overloads or template variants. In some cases you really need a typecast, not only for ifelse.
Re: New Zorro version 2.50
[Re: jcl]
#486336 08/02/2217:2208/02/2217:22
Hi, I am having difficulty to install the 2.50.2 Version. The error message is, that the VCRUNTIME140.dll is missing and the advice to reinstall. With the 64-bit version also no success, complains about missing mfc140.dll. I have uninstalled all old versions, and installed from scratch, the same error messages. Is it a bug or some setup problem of my desktop ? I mean the Zorro is installed with no error message, but Zorro.exe does not start.
Thank you for any advice, ...
Last edited by hast29; 08/05/2210:41.
Re: New Zorro version 2.50
[Re: jcl]
#486356 08/05/2211:0308/05/2211:03
and unzip it in the Zorro folder or in your windows/system32 folder. Maybe it's not the only DLL missing - please let us know if you then still get a missing DLL error. We'll pack all those DLLs in the setup.
The 64 bit version won't directly run on your PC anyway. You must really install the 64 bit runtime as described in the manual.
Re: New Zorro version 2.50
[Re: jcl]
#486357 08/05/2213:2908/05/2213:29
Hi jcl and thank you for the prompt support. The library did not help. After unzipping it into Zoro folder, the application does not start again and this time with just a message "the application could not be started", no hints about any other missing libraries. Do I understand you properly, if I install the 64bit MS Visual Studio in the computer, the problem will be solved ? MS Visual Studio is now free, so this is for me no extra costs option. Also, is there any benefit from 64bit architecture ? I am just training and testing own scripts, writen directly in Zorro "simple C".
Re: New Zorro version 2.50
[Re: hast29]
#486358 08/05/2214:0108/05/2214:01
Also, is there any benefit from 64bit architecture ? I am just training and testing own scripts, writen directly in Zorro "simple C".
Quote
Using C++ as script language has many advantages. Additional development tools, such as the Visual Studio debugger and profiler, are available. External libraries, such as Boost, can be integrated without a wrapper. The 64-bit mode can access more memory for backtests. All lite-C functions and all system variables can still be used, but additionally you have C++ classes and templates at your disposal. Error handling is more strict and you'll get warnings about bad code style. The VC++ compiler is a bit slower than the lite-C on-the-fly compiler, but is only invoked when the script was changed. The resulting code runs equally fast or - in 64 bit mode - even faster. The only disadvantage is that you have to download and install Microsoft Visual Studio™ 2017 or above.
Do I understand you properly, if I install the 64bit MS Visual Studio in the computer, the problem will be solved ? MS Visual Studio is now free, so this is for me no extra costs option.
You will need Visual Studio for programming in C++, but not for merely running Zorro. The VC++ runtime would solve your problem. But we prefer no runtime installation for the 32 bit version, so we want to include the dlls directly. We had not had a PC so far where the 32 bit version would require a runtime. What's your Windows version?
Re: New Zorro version 2.50
[Re: jcl]
#486360 08/05/2217:2008/05/2217:20
Ok. Unpack FXCM.zip into the Zorro folder. The FXCM API is a 32 bit VC application and should thus enable your PC to also run the 32 bit Zorro without VC runtime, no matter what DLL was missing before. Let me know if this works.
For 64 bit you'll need the VC runtime in any case.
Re: New Zorro version 2.50
[Re: jcl]
#486362 08/07/2210:0008/07/2210:00
Hi guys. I migrated my lite-C script to C++ to test the new feature "C++ scripts now start directly, like .c scripts (Zorro S and Visual Studio required). "
I found it only works when the script name is different. For example if you have script names:
Test1.c Test1.cpp
and you click Test on Zorro64 for Test1 it will print "Test1" but it won't compile it; it just does nothing. The documentation states:
"If you have a mix of lite-C and C++ scripts, you can add a '+' to a .cpp script name for marking it in the scrollbox"
I tried this to name it Test1+.cpp and it compiled and ran as expected. Would it be possible to tighten the documentation wording a bit to say it must have different names if using a mix of lite-C and C++ files, or give some error message to indicate needing a different script name when trying to run it in Zorro64?
EDIT: I then tried creating the DLL directly from Visual Studio. When building it as Test1+.dll I get the same issue - Zorro64 prints "Test1+" then does nothing. However when I change the output dll name to Test1+64.dll then Zorro64 uses it correctly. But suffixing the 64 on the dll name is not mentioned in the help pages, I just figured it out from the way Zorro was building the included MyStrategy+.cpp
Last edited by mun; 08/07/2213:05.
Re: New Zorro version 2.50
[Re: jcl]
#486363 08/08/2207:2908/08/2207:29
You need indeed different names for different scripts, otherwise .c will override .cpp. This will be mentioned more clearly in the manual.
"64" has no meaning in a script name. If you compiled a script with 32 bit, you must run it with 32 bit. You cannot run a 32 bit dll with a 64 bit program. It will simply not load.
Re: New Zorro version 2.50
[Re: jcl]
#486388 08/09/2215:5008/09/2215:50
Hi jcl, yes unpacking FXCM.zip solved the issue for the 32-bit. Zorro 2.50.2 starts and runs OK now, on my desktop computer.
I will not yet use the 64-bit Version and the C++ coding. Perhaps later.The advantages mentioned by AndrewAMD could be of a good use for me, when I progress more with my programming skills.
I am all set now with the new 2.50.2, thank you for the support.
Re: New Zorro version 2.50
[Re: jcl]
#486685 09/17/2213:2909/17/2213:29
Just following up on the post from “mun” above, and have noticed the Zorro64 dll name dependency (for Zorro 2.50).
I have reduced the script to very basic functionality – it prints out “main” from main() and “INITRUN” from run().
When I manually compile the script in Visual Studio as a x32, it (Test.dll) loads and “tests” fine from Zorro(32). Testing from Zorro64 just prints two empty lines followed by the name of the script on the third line (in the Zorro64 status box) – no error message.
When I compile the script in Visual Studio as a x64, in Zorro(32) it tries to load (when Test is clicked) and then produces an Error 061: invalid DLL (….). This is expected behaviour.
When I load/Test the same x64 dll strategy file in Zorro64, it just does the same as previous - prints the two empty lines followed by the name of the script - nothing else. It does the same when it loads other x32 strategy files (two empty lines and the name of the file).
When I rename the x64 dll strategy file to Test64.dll, the Script retains the same name in Zorro64 but it now executes properly. Zorro64 is truncating the 64 from the name of the dll file (i.e. If I rename the x64 dll to Test6464.dll, Zorro64 shows the name as Test64).
Lastly, if I rename a x32 dll strategy file to include 64 at the end of the name, Zorro64 then tells me that it’s an invalid DLL. I can’t think why I would do this in reality – just including for completeness.
So Zorro64 is using the ending part of the compiled strategy dll to figure out if should be executed as a x64. If it’s not present, then Zorro64 won’t even try to execute it as a x64. While “64” has no meaning in a script source name, it does indeed have a meaning in the compiled dll name (as far as Zorro64 is concerned).
It took me a few hours of mucking about today to see what I was doing wrong. I couldn’t find anything in the documentation indicating that I need to rename the x64 Visual Studio compiled .dll to get it working in Zorro64 - perhaps this could be included in future versions of the documentation.
Regards,
Kieran
Last edited by Sc1entia; 10/15/2216:55.
Re: New Zorro version 2.50
[Re: jcl]
#486820 10/16/2205:2910/16/2205:29
2.50 seems to have changed the way Zorro handles the Broker drop-down and introduced a bug - or at least an annoyance.
In 2.48 pressing the Broker drop-down gave a list of all the Brokers. In 2.50, the drop-down is 1 long, only showing Ally. The correct Broker can still be selected via careful scrolling or the arrow keys, but on first appearance it looks like only Ally exists! This is running under Wine. I have not tried on a Windows machine.
Re: New Zorro version 2.50
[Re: jcl]
#486821 10/16/2206:4710/16/2206:47
2.50.2 is the release version. The dropdown has not changed, but is anyway not release dependent because it's rendered by Windows MFC. Do you see only the first entry in the dropdown list, but can see all when scrolling? Is it only the broker scrollbox, or all scrollboxes? Can you post a screenshot?
Re: New Zorro version 2.50
[Re: jcl]
#486833 10/19/2200:4210/19/2200:42
- Broker dropdown is 1 line - Initially shows last Broker used - Scrolling works with either mouse wheel or arrows - Dropdown remains 1 line - Only Broker dropdown - all other dropdowns are fine - 2.48 on same machine in same Wine prefix works fine
I've never posted a screenshot - can that be done inline?
Thanks.
Re: New Zorro version 2.50
[Re: DdlV]
#486836 10/19/2208:2610/19/2208:26
Thanks, the description is enough. It's a bit mysterious why it only affects the broker scrollbox and only in a certain version, but maybe it's some random effect. We'll check if we can find some pattern to it, and will also inform the Wine team (but with not much hope).
Re: New Zorro version 2.50
[Re: jcl]
#486879 11/06/2213:1011/06/2213:10
Noticed 2 problems (I'm running 2.50.2 development version on Wine/Ubuntu 22.04)
1. The list of brokers is different if I launch 64-bit version vs 32-bit. 64-bit version contains only "MT4/5 demo" and "Offline". I get more in the 32-bit version. This is my .desktop file (for staring 64-bit on Ubuntu)
2. UI issue on resizing the window in "Strategy" groupbox (see the screenshot.png). If I click on dropdown boxes they are refreshed and displayed properly afterwards. Same behavior for 32-bit and 64-bit versions.
Re: New Zorro version 2.50
[Re: jcl]
#486880 11/06/2215:3311/06/2215:33