Subscribe Bookmark RSS Feed

Variable format in global box

I need to keep "ss" in date format when I adjust sliderbox. However, it turns out to be number.
Any suggestions? thanks

<---
ss=15aug2010;
new window("new window",sliderbox(1aug2010,30aug2010,ss),globalbox(ss));

--->
3 REPLIES
mpb

Super User

Joined:

Jun 23, 2011

Try this. Still would be nice to get rid of the quotes being displayed, but it may be a start. The show(css) is just for testing.


style="font-size: 10pt; font-family: "Courier New"; color: black;">ss

style="font-size: 10pt; font-family: "Courier New"; color: navy;">=

style="font-size: 10pt; font-family: "Courier New"; color: black;">
15aug2010

style="font-size: 10pt; font-family: "Courier New"; color: navy;">;

style="font-size: 10pt; font-family: "Courier New"; color: black;">




style="font-size: 10pt; font-family: "Courier New"; color: rgb(0, 0, 221);">New
Window

style="font-size: 10pt; font-family: "Courier New"; color: black;">(

style="font-size: 10pt; font-family: "Courier New"; color: black;">

style="font-size: 10pt; font-family: "Courier New"; color: purple;">"new
window"

style="font-size: 10pt; font-family: "Courier New"; color: navy;">,

style="font-size: 10pt; font-family: "Courier New"; color: black;">



     

style="font-size: 10pt; font-family: "Courier New"; color: rgb(0, 0, 221);">Slider
Box

style="font-size: 10pt; font-family: "Courier New"; color: black;">(

style="font-size: 10pt; font-family: "Courier New"; color: black;">
1aug2010

style="font-size: 10pt; font-family: "Courier New"; color: navy;">,

style="font-size: 10pt; font-family: "Courier New"; color: black;">
30aug2010

style="font-size: 10pt; font-family: "Courier New"; color: navy;">,

style="font-size: 10pt; font-family: "Courier New"; color: black;">
ss

style="font-size: 10pt; font-family: "Courier New"; color: navy;">,

style="font-size: 10pt; font-family: "Courier New"; color: black;">
css

style="font-size: 10pt; font-family: "Courier New"; color: navy;">=

style="font-size: 10pt; font-family: "Courier New"; color: rgb(0, 0, 221);">format

style="font-size: 10pt; font-family: "Courier New"; color: black;">(

style="font-size: 10pt; font-family: "Courier New"; color: black;">ss

style="font-size: 10pt; font-family: "Courier New"; color: navy;">,

style="font-size: 10pt; font-family: "Courier New"; color: purple;">"ddmonyyyy"

style="font-size: 10pt; font-family: "Courier New"; color: black;">)

style="font-size: 10pt; font-family: "Courier New"; color: navy;">;

style="font-size: 10pt; font-family: "Courier New"; color: rgb(0, 0, 221);">show

style="font-size: 10pt; font-family: "Courier New"; color: black;">(

style="font-size: 10pt; font-family: "Courier New"; color: black;">css))

style="font-size: 10pt; font-family: "Courier New"; color: navy;">,

style="font-size: 10pt; font-family: "Courier New"; color: rgb(0, 0, 221);">Global
Box

style="font-size: 10pt; font-family: "Courier New"; color: black;">(

style="font-size: 10pt; font-family: "Courier New"; color: black;">
css )




style="font-size: 10pt; font-family: "Courier New"; color: black;">)

style="font-size: 10pt; font-family: "Courier New"; color: navy;">;

This variation on the same theme seems to do it without the quotes:


style="font-size: 9pt; font-family: "Courier New"; color: black;">



ss

style="font-size: 9pt; font-family: "Courier New"; color: navy;">=

style="font-size: 9pt; font-family: "Courier New"; color: black;">
15aug2010

style="font-size: 9pt; font-family: "Courier New"; color: navy;">;

style="font-size: 9pt; font-family: "Courier New"; color: black;">





style="font-size: 9pt; font-family: "Courier New"; color: black;">TextBox_Date

style="font-size: 9pt; font-family: "Courier New"; color: navy;">=

style="font-size: 9pt; font-family: "Courier New"; color: black;">

style="font-size: 9pt; font-family: "Courier New"; color: rgb(0, 0, 221);">TextBox

style="font-size: 9pt; font-family: "Courier New"; color: black;">(

style="font-size: 9pt; font-family: "Courier New"; color: rgb(0, 0, 221);">format

style="font-size: 9pt; font-family: "Courier New"; color: black;">(

style="font-size: 9pt; font-family: "Courier New"; color: black;">ss

style="font-size: 9pt; font-family: "Courier New"; color: navy;">,

style="font-size: 9pt; font-family: "Courier New"; color: black;">

style="font-size: 9pt; font-family: "Courier New"; color: purple;">"ddmonyyyy"

style="font-size: 9pt; font-family: "Courier New"; color: black;">))

style="font-size: 9pt; font-family: "Courier New"; color: navy;">;

style="font-size: 9pt; font-family: "Courier New"; color: black;">





style="font-size: 9pt; font-family: "Courier New"; color: black;">

 





style="font-size: 9pt; font-family: "Courier New"; color: black;">Show_Date

style="font-size: 9pt; font-family: "Courier New"; color: navy;">=

style="font-size: 9pt; font-family: "Courier New"; color: black;">

style="font-size: 9pt; font-family: "Courier New"; color: rgb(0, 0, 221);">function

style="font-size: 9pt; font-family: "Courier New"; color: black;">({

style="font-size: 9pt; font-family: "Courier New"; color: black;">DateValue}

style="font-size: 9pt; font-family: "Courier New"; color: navy;">,

style="font-size: 9pt; font-family: "Courier New"; color: black;">





style="font-size: 9pt; font-family: "Courier New"; color: black;">
style="">      
TextBox_Date

style="font-size: 9pt; font-family: "Courier New"; color: navy;"><<

style="font-size: 9pt; font-family: "Courier New"; color: black;">
set text(

style="font-size: 9pt; font-family: "Courier New"; color: rgb(0, 0, 221);">format

style="font-size: 9pt; font-family: "Courier New"; color: black;">(

style="font-size: 9pt; font-family: "Courier New"; color: black;">DateValue

style="font-size: 9pt; font-family: "Courier New"; color: navy;">,

style="font-size: 9pt; font-family: "Courier New"; color: black;">

style="font-size: 9pt; font-family: "Courier New"; color: purple;">"ddmonyyyy"

style="font-size: 9pt; font-family: "Courier New"; color: black;">))

style="font-size: 9pt; font-family: "Courier New"; color: navy;">;

style="font-size: 9pt; font-family: "Courier New"; color: black;">





style="font-size: 9pt; font-family: "Courier New"; color: black;">
style="">      
nw

style="font-size: 9pt; font-family: "Courier New"; color: navy;"><<

style="font-size: 9pt; font-family: "Courier New"; color: black;">
reshow

style="font-size: 9pt; font-family: "Courier New"; color: navy;">;

style="font-size: 9pt; font-family: "Courier New"; color: black;">





style="font-size: 9pt; font-family: "Courier New"; color: black;">
style="">      
)

style="font-size: 9pt; font-family: "Courier New"; color: navy;">;

style="font-size: 9pt; font-family: "Courier New"; color: black;">





style="font-size: 9pt; font-family: "Courier New"; color: black;">
style="">      




style="font-size: 9pt; font-family: "Courier New"; color: black;">nw

style="font-size: 9pt; font-family: "Courier New"; color: navy;">=

style="font-size: 9pt; font-family: "Courier New"; color: black;">

style="font-size: 9pt; font-family: "Courier New"; color: rgb(0, 0, 221);">New
Window

style="font-size: 9pt; font-family: "Courier New"; color: black;">(

style="font-size: 9pt; font-family: "Courier New"; color: purple;">"New
Window"

style="font-size: 9pt; font-family: "Courier New"; color: navy;">,

style="font-size: 9pt; font-family: "Courier New"; color: black;">





style="font-size: 9pt; font-family: "Courier New"; color: black;">
style="">      

style="font-size: 9pt; font-family: "Courier New"; color: rgb(0, 0, 221);">LineUpBox

style="font-size: 9pt; font-family: "Courier New"; color: black;">(

style="font-size: 9pt; font-family: "Courier New"; color: rgb(0, 0, 221);">ncol

style="font-size: 9pt; font-family: "Courier New"; color: black;">(

style="font-size: 9pt; font-family: "Courier New"; color: teal;">2

style="font-size: 9pt; font-family: "Courier New"; color: black;">)

style="font-size: 9pt; font-family: "Courier New"; color: navy;">,

style="font-size: 9pt; font-family: "Courier New"; color: black;">





style="font-size: 9pt; font-family: "Courier New"; color: black;">
style="">             

style="font-size: 9pt; font-family: "Courier New"; color: rgb(0, 0, 221);">Slider
Box

style="font-size: 9pt; font-family: "Courier New"; color: black;">(

style="font-size: 9pt; font-family: "Courier New"; color: black;">1aug2010

style="font-size: 9pt; font-family: "Courier New"; color: navy;">,

style="font-size: 9pt; font-family: "Courier New"; color: black;">
30aug2010

style="font-size: 9pt; font-family: "Courier New"; color: navy;">,

style="font-size: 9pt; font-family: "Courier New"; color: black;">
ss

style="font-size: 9pt; font-family: "Courier New"; color: navy;">,

style="font-size: 9pt; font-family: "Courier New"; color: black;">
Show_Date(ss))

style="font-size: 9pt; font-family: "Courier New"; color: navy;">,

style="font-size: 9pt; font-family: "Courier New"; color: black;">
TextBox_Date





style="font-size: 9pt; font-family: "Courier New"; color: black;">
style="">             
)





style="font-size: 9pt; font-family: "Courier New"; color: black;">
style="">      
)

style="font-size: 9pt; font-family: "Courier New"; color: navy;">;
that works thanks a lot guys.