Alexis Posted April 25, 2010 Report Share Posted April 25, 2010 Hi everybody, i need to type out the date of the next monday (regardless of the actual day). Somehow i struggle with the date/decimal variables / converting functions. I just don´t seem to get it. I´m quite sure that MEX Pro can calculate the date of the next monday and type that in an specific window. Has anybody experience in date variables / calculations? Thank You Alexandra Quote Link to comment Share on other sites More sharing options...
rberq Posted April 25, 2010 Report Share Posted April 25, 2010 I don't think you have to use a decimal variable as such. Use the new date/time variable format, like this: Date/Time command to create a date/time variable, give it a name like datx, and set it to current date/time (this is all done in one command). Variable Modify Date/Time: Convert %datx% to Text String (use the "ddd" option which puts Mon, Tue, Wed, etc. in the text variable T[1]) Series of IF commands to add to datx, based on what is in T[1] -- for example IF %T[1]% = SUN Variable Modify Date/Time: %datx% = %datx% + 1 day END IF IF %T[1]% = SAT Variable Modify Date/Time: %datx% = %datx% + 2 days END IF Variable Modify Date/Time: Convert to Text String (use the "m/d/yyyy" option, or whatever format you want, to put 4/26/2010 in the text variable T[1]) Text type T[1] or Text Box Display T[1] Quote Link to comment Share on other sites More sharing options...
Alexis Posted April 25, 2010 Author Report Share Posted April 25, 2010 Thanks a lot rberq. That was quick help!! I learned a new command (Date/Time) today! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.