[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [amibroker] Different curency databases -- an AB pain in the butt?



PureBytes Links

Trading Reference Links

Yuki,

Just a thought and it is not much of a change to your formula. This type of formula it will perform the change automatically for you depending on the database you have opened. Just change the names from Yen and USD to the real names you have given to your databases (case sensitive)

if ( GetDatabaseName() == "Yen" )
x = 1.2;
else if ( GetDatabaseName() == "USD" )
x = 1.0;
else
x = 1.0;

Title = Name() + "  -  " + WriteVal( DateTime(), formatDateTime ) + 
"  - " + " Open: " + EncodeColor(colorYellow) + WriteVal(O,x) + " " + 
EncodeColor(colorBlack)+ 
" -  Hi: " + EncodeColor(colorRed)+WriteVal(H,x) + 
" " + EncodeColor(colorBlack) + 
" -  Low: " + EncodeColor(colorBrightGreen) + WriteVal(L,x) +
" " + EncodeColor(colorBlack) + 
" -  Close: " + EncodeColor(colorYellow) + WriteVal(C,x) + 
EncodeColor(colorBlack) + "-  Volume: " + WriteVal(V,1);


Regards,
William Peters
www.amitools.com



-----Original Message-----
From: Yuki Taga [mailto:yukitaga@xxxxxxxxxxxxx]
Sent: September 10, 2003 5:18 PM
To: Tomasz Janeczko
Subject: Re: [amibroker] Different curency databases -- an AB pain in
the butt?


Hi Tomasz,

Wednesday, September 10, 2003, 8:21:48 PM, you wrote:

TJ> Layouts are stored PER DATABASE, therefore there is no obstacle
TJ> in using different set of indicators/charts/formulas in different databases.

TJ> Please check Tutorial: Working with chart sheets and window layouts

I have looked at this "tutorial" in the past, but it doesn't put
things in a way that I can understand, and I am very reluctant to
start playing around with settings that I do not fully understand,
having put tremendous time and effort into getting things set up
reasonably the way I like them for my Japanese database.

Question for you or anyone:

1) If I modify a custom price chart, then save that as a local
layout, is the global default layout then immune to this modification
when I change databases?

For example, in one of my custom price charts, I have the following:

Title = Name() +"  -  "+ WriteVal( DateTime(), formatDateTime )+"  -
"+"Open: "+EncodeColor(colorYellow)+WriteVal(O,1.0)+"
"+EncodeColor(colorBlack)+" -  Hi:
"+EncodeColor(colorRed)+WriteVal(H,1.0)+" "+EncodeColor(colorBlack)+"
-  Low: "+EncodeColor(colorBrightGreen)+WriteVal(L,1.0)+"
"+EncodeColor(colorBlack)+" -  Close:
"+EncodeColor(colorYellow)+WriteVal(C,1.0)+EncodeColor(colorBlack)+"
-  Volume: "+WriteVal(V,1);

This is perfect for the yen, which is indivisible.  But I'd like to
modify this for the dollar, which would mean changing all the '1.0'
settings to '1.2', I believe.  (This also affects the pop up values,
of course.)

But I doubt if I can modify a formula for a custom indicator, and not
have the change take place globally.  Am I wrong?  The tutorial
doesn't speak to this, or at least not in a way that I can
understand.

Yuki



Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx 
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html 

Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/ 



------------------------ Yahoo! Groups Sponsor ---------------------~-->
Buy Ink Cartridges or Refill Kits for Your HP, Epson, Canon or Lexmark
Printer at Myinks.com. Free s/h on orders $50 or more to the US & Canada. http://www.c1tracking.com/l.asp?cid=5511
http://us.click.yahoo.com/l.m7sD/LIdGAA/qnsNAA/GHeqlB/TM
---------------------------------------------------------------------~->

Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx 
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html 

Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/