atr0037 New User Joined: 27 Jan 2013 Posts: 1 Location: Portugal
Hi, due a metter of time zones, I'm trying to use the following formula in OPC, but I'ts giving me error. What I want to acheive is to get the previous day before the next working day.
I'm trying to do the followig:
/LUSER01A JOB (885002,NOBO),SAMPLE,NOTIFY=XSTEVEN,MSGCLASS=Q,
//*%OPC SETFORM OCDATE=(CCYYMMDD)
//*%OPC SETVAR TEST=(OCDATE + 1WD - 1CD)
The last instruction is giving error.
Does anyone have an ideia how to do this ?
Thank you in advance!
PeterHolland Global Moderator Joined: 27 Oct 2009 Posts: 2472 Location: Netherlands, Amstelveen
It would have been nice if you had mentioned the error, that makes resolving the problem a bit easier.
My guess is that you can only use 1 arithmetic operation in a SETVAR, so
maybe the following will work :
//*%OPC SETVAR TEST=(OCDATE + 1WD)
//*%OPC SETVAR TEST=(TEST - 1CD)
All times are GMT + 6 Hours