Subj : Right Justify To : DesotoFireflite From : Digital Man Date : Tue Dec 29 2020 03:15 pm Re: Right Justify By: DesotoFireflite to Digital Man on Tue Dec 29 2020 04:44 pm > Re: Right Justify > By: Digital Man to DesotoFireflite on Mon Dec 28 2020 02:37 pm > > DM> var lastCallerStr = format("\1h\1c%5u \1h\1c%5u", tlogons, firstOn); > > DM> That print the integers ('u' means unsigned integer) right-justified to > DM> 5 characters (minimum), using spaces for padding. If you wanted > DM> 0-padding instead, then you'd specify "%05u". If you want > DM> left-justification, use "%-5u". -- > > Ok, I think I got that, and I have managed to make it work with different > colors for anything that uses strictly numbers, but lets say there is a > alias field, and a date field, if I use the u, which applies to intergers, I > get in the field, and if I leave out the padding and justifaction, I > get a blank screen. > > var lastCallerStr = format("\1h\1c%5u \1h\1r%2u \1h\1g%2u", tlogons, age, > sec); > > The above works as is, but what would I use instead of a u to format the > alias and a date field with color. I tried to find the answer on my own > looking at the js object model, but no luck. I guess what do i use in place > of the u for text and dates. > > var lastCallerStr = "\1h\1b" + alias + " " + "\1h\1y" + lastOn; > > Thanks, as always. I beginning to think, that this is way over my head :( You would use %s instead of %u: https://en.wikipedia.org/wiki/Printf_format_string -- digital man Synchronet/BBS Terminology Definition #33: FTN = FidoNet Technology Network Norco, CA WX: 57.3øF, 43.0% humidity, 11 mph ESE wind, 0.53 inches rain/24hrs .