Gamestudio Links
Zorro Links
Newest Posts
Blobsculptor tools and objects download here
by NeoDumont. 03/28/24 03:01
Issue with Multi-Core WFO Training
by aliswee. 03/24/24 20:20
Why Zorro supports up to 72 cores?
by Edgar_Herrera. 03/23/24 21:41
Zorro Trader GPT
by TipmyPip. 03/06/24 09:27
VSCode instead of SED
by 3run. 03/01/24 19:06
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
3 registered members (VoroneTZ, monk12, Quad), 829 guests, and 4 spiders.
Key: Admin, Global Mod, Mod
Newest Members
sakolin, rajesh7827, juergen_wue, NITRO_FOREVER, jack0roses
19043 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Help in finding the missing snippet #467110
07/16/17 09:00
07/16/17 09:00
Joined: Feb 2015
Posts: 652
Milano, Italy
M
MatPed Offline OP
User
MatPed  Offline OP
User
M

Joined: Feb 2015
Posts: 652
Milano, Italy
Hi,
I remember that there was in the manual or in a forum post a snippet to print the Algos result as in z systems.
Something that print results as:
EUR/USD CT:L -62
USD/CHF CT:LS -130 HP:S +35
GBP/USD BB:LS +634 CY:LS +466
USD/CAD CT:LS -139
USD/JPY CT:L +884 CY:L +3464
AUD/USD HP:S +1076
NAS100 BB:L +797 CY:L +1768 HP: +5861
SPX500 CY:L -120 HP:L +51
US30 CT:L +1110 CY:LS +688
GER30
XAU/USD HP:LS +4231
XAG/USD HP:LS +3347
UK100 CY:LS +325 HP:L +526

but I can not find it anymore. Has somebody the right like to the manual page and/or forum post?

Thank you in advance

Re: Help in finding the missing snippet [Re: MatPed] #467124
07/17/17 09:30
07/17/17 09:30
Joined: Jul 2000
Posts: 27,977
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,977
Frankfurt
This is some of the code for a cell in the results table in Z1/Z2:

Code:
print(TO_HTML,"<td");
if(NumWinLong+NumLossLong+NumWinShort+NumLossShort > 0) {
	print(TO_HTML," bgcolor=\"#FF0000\"");
	print(TO_HTML,">%s:",Algo);
	if(NumWinLong+NumLossLong > 0) print(TO_HTML,"L"); 
	if(NumWinShort+NumLossShort > 0) print(TO_HTML,"S");
	print(TO_HTML," %+.0f",ProfitClosed+ProfitOpen);
} else
	print(TO_HTML,">");
print(TO_HTML,"</td>");


Re: Help in finding the missing snippet [Re: jcl] #467125
07/17/17 09:32
07/17/17 09:32
Joined: Feb 2015
Posts: 652
Milano, Italy
M
MatPed Offline OP
User
MatPed  Offline OP
User
M

Joined: Feb 2015
Posts: 652
Milano, Italy
God Bless you! laugh

Re: Help in finding the missing snippet [Re: MatPed] #467589
08/14/17 17:28
08/14/17 17:28
Joined: Feb 2015
Posts: 652
Milano, Italy
M
MatPed Offline OP
User
MatPed  Offline OP
User
M

Joined: Feb 2015
Posts: 652
Milano, Italy
Hi Jcl,
I gave a look to the code and I understand that you are playing in another league from a coding perspective, but I really need some explanation, because the code snippet you have posted is obscure to a simple mind like me laugh
I am stuck with the first line what is the "<td" string?
I do not understand the logic the snippet is printing only from the algo, nothing is printed regarding the Asset.
Should i call the snippet to update the Status report within the Algo/Asset loop or is better in a tick/tok function?

Thank you

Re: Help in finding the missing snippet [Re: MatPed] #467592
08/15/17 06:54
08/15/17 06:54
Joined: Feb 2017
Posts: 369
D
Dalla Offline
Senior Member
Dalla  Offline
Senior Member
D

Joined: Feb 2017
Posts: 369
<td is just partial HTML code.

The output will read something like
<td bgcolor="#FF0000">MyAlgoName: L 100</td>
or just
<td></td> (empty cell)
depending on the evaluation of the if/else block

Re: Help in finding the missing snippet [Re: Dalla] #467593
08/15/17 16:22
08/15/17 16:22
Joined: Feb 2015
Posts: 652
Milano, Italy
M
MatPed Offline OP
User
MatPed  Offline OP
User
M

Joined: Feb 2015
Posts: 652
Milano, Italy
ok, thank you for your answer my html knowledge is zero!
Probably this is the reason I am struggling formatting a decent output with Zorro!

Ciao


Moderated by  Petra 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1