These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

Why doesn't this work???

josixpack
Registered: Jan 4 2010
Posts: 9

I know nothing about LiveCycle Designer and i'm trying to figure somethings out so i can create a timesheet form. Why won't this work, if (Field1 = 1) then Field2 = 40 else 0 endif??

gkaiseril
Online
Expert
Registered: Feb 23 2006
Posts: 4307
Have you looked at the 'Scripting Reference' under LiveCycle Designer's 'Help'?

The '=' is the set equal to operator and not one of the equality comparison operators, '==' or 'eq'.

George Kaiser

jonom
Registered: Jan 31 2008
Posts: 133
I think that should be:

if (Field1 == 1)
then
Field2 = 40
else
Field2 = 0
endif

You use two "==" for testing values and one "=" for assigning values. Also you didn't state what you wanted to be "0".
josixpack
Registered: Jan 4 2010
Posts: 9
I looked at the Scripting Reference but got confused very quickly. I don't have any programming experience and can barely use MS Excel. Using the '==' worked but not quite the way I wanted.

I was hoping to have a dropdown box called PayDate with specific dates to choose from, once a date is selected it would populate other fields with different dates. Example if PayDate = January 31st 2010 then there would be a Monday field which would be populated with January 18th 2010 and then a Tuesday field which would populate with January 19th 2010 and so on for the rest of the days of the week in that pay period. Any suggestions for that?

Does anyone know of someone or a company i could send what i have created so far for a timesheet and tell them what i want it to do and they would finish or create it for me?

Thanks for your help!

Joe
josixpack
Registered: Jan 4 2010
Posts: 9
Off topic but from your picture Jonom you possible appear to be a fellow mountain biker. Man you got some amazing riding and riders up there.

Joe
jonom
Registered: Jan 31 2008
Posts: 133
Yeah, that's getting pretty tricky and if you're not into scripting you'll find it a bear. Beyond my scripting skills at the moment.

There are some form developers on the forum so maybe they can help.

And yes, I'm a mountain biker and cyclist. I'm not a great mountain biker but yeah we've got some great riding.