The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
 All Forums
 Origin Forum
 Origin Forum
 Time & Date Stamp

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

Screensize:
UserName:
Password:
Anti-Spam Code:
Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkUpload FileInsert Image Insert CodeInsert QuoteInsert List
   
Message:

* HTML is OFF
* Forum Code is ON
Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Clown [:o)]
Black Eye [B)] Eight Ball [8] Frown [:(] Shy [8)]
Shocked [:0] Angry [:(!] Dead [xx(] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
Mark H Ungurian Posted - 03/22/1999 : 3:05:00 PM
How can I format the time&date stamp on a graph to show ie. March 22/99 instead of the usual 3/22/99 13:20:18? I've searched all over the place, but I keep comming up empty.
Thanks. MHU.

Hi Greg
This is exactly what I was looking for
The origin tip works well.
Thanks again!

[This message has been edited by Mark H Ungurian (edited 03-24-99).]

1   L A T E S T    R E P L I E S    (Newest First)
greg Posted - 03/23/1999 : 5:16:00 PM
The Date & Time button on the Graph toolbar runs a script in the [DateTime] section of the STANDARD.OGS file. That script consists of

label -s -sa -d (.6*page.width) (.05*page.height) -n timestamp $(@D,D10);

The $(@D,D10) is the key to customizing the format. In this case we are asking for the 10th (numbered from zero) date format from the Origin Date Format list (which is M/D/YYYY HH:MM:SS).

In your case, getting the precise format you want could be quite complicated. For an example that doesn't deal with the 'leading zero' issue, try:

%A=$(@D,D11);
%B=January February March April May June July August September October November December;
%M=%[%A,3:4];
month=$(%M);
%M=%[%B,#$(month)] %[%A,5:6]/%[%A,1:2];
label -s -sa -d (.6*page.width) (.05*page.height) -n timestamp %M;

Consult Substring Notation in the LabTalk manual (page 14) for other options.



** Origin Tip **********************************************************
* Check to see if Origin uses a LabTalk script for a tool or menu: *
* (1) Open the Script window by selecting Window:Script Window *
* (2) Hold Down the Ctrl AND Shift Keys (just Ctrl for 4.x) *
* (3) Select the menu option you want to test *
* If the option runs a LabTalk script, that script types to the Script *
* window, but does not execute. *
* *
* You may see something like: *
* run.section(GRANALY,LowPass) *
* which opens the file named GRANALY.OGS and runs the script in the *
* [LowPass] section. *
************************************************************************

The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000