since ‎10-12-2009
‎10-12-2019
Level 1
Display/Hide Decimal

Gene--O

Total Posts

76

Likes

3

0
Gene--O
Good Morning,This seems very simple, but I can't figure it out:I have a numeric field that I need a user to enter a number. This number can be either whole or a decimal with 2 trailing values after the decimal point. For example:11.151.30 etc.I need the field to display the whole number if there is no decimal value, but if there is a decimal value then I need the field to always display 2 numbers after the decimal. I have gotten the field to show the first two examples above, but in the 3rd exam...

Views

755

Likes

0

Replies

1
Re: calculating times in 15 minute increments

Gene--O

Total Posts

76

Likes

3

0
Gene--O
Thanks for responding. It’s a bit too much for me also!!

Views

7.1K

Likes

0

Replies

0
Re: Adding hours & minutes

Gene--O

Total Posts

76

Likes

3

0
Gene--O
Paul,I ran across this OLD thread while researching a problem and hoped you could expand just a bit.I am trying to add hours and minutes, just as above. However, I report everything in fifteen minute increments.Example: 1.15 = one hour fifteen minutes 1.30 = one hour thirty minutesWhen I add as you suggested, I get 165 minutes / 60 = 2.75 hours. I need this answer to display as 2.45 (two hours and 45 minutes). If I add these with normal math, the above problem works correctly, but the answer doe...

Views

346

Likes

0

Replies

0
Re: calculating times in 15 minute increments

Gene--O

Total Posts

76

Likes

3

0
Gene--O
Also, this seems to want to do traditional math, instead of dealing with 15 minute increments, or am I missing something?

Views

7.1K

Likes

0

Replies

0
Re: calculating times in 15 minute increments

Gene--O

Total Posts

76

Likes

3

0
Gene--O
I’m so sorry, but I am lost! I have not had any training in scripting and trying to learn on my own….

Views

7.1K

Likes

0

Replies

0
Re: calculating times in 15 minute increments

Gene--O

Total Posts

76

Likes

3

0
Gene--O
I’m sorry, you lost me!

Views

7.1K

Like

1

Replies

0
Re: calculating times in 15 minute increments

Gene--O

Total Posts

76

Likes

3

0
Gene--O
Thanks again!But this only works if I am inputting only “25”, “50”, or “75”. Not if I enter numbers with decimals such as “1.25”. Can I use a wildcard to represent the whole number?

Views

7.1K

Likes

0

Replies

0
Re: calculating times in 15 minute increments

Gene--O

Total Posts

76

Likes

3

0
Gene--O
Thanks so much for trying to help!!I need to calculate leave taken by an employee in 15 minute intervals.For example: 1.15 hours of vacation (one hour and fifteen minutes)+2.30 hours of holiday leave (two hours and thirty minutes)+ 4.45 hours of sick leave (four hours and forty-five minutes)= 8.30 hours of total leave taken (eight hours and thirty minutes)Anything I try has calculated it as:1.252.504.75=8.50I have to have it formatted in 15 minute increments instead of decimalsAny ideas?Gene-O

Views

7.1K

Likes

0

Replies

0
calculating times in 15 minute increments

Gene--O

Total Posts

76

Likes

3

0
Gene--O
Good Afternoon,I am making a form where we report how much leave is being used. The leave will be reported in 15 minute increments. (Ex: fifteen minutes = .15; one-half hour = .30; 45 minutes = .45) I need to be able to add these up and have them keep this format of 15 minute increments. Also, I need the display to be a decimal instead of a colon, if possible. (Ex. 3.45 instead of 3:45).any advice is appreciated!!!Gene-O

Views

33.1K

Like

1

Replies

12
Re: Filling a form based on a Table

Gene--O

Total Posts

76

Likes

3

0
Gene--O
thanks for the reply, I'll give it a shot!!!

Views

334

Likes

0

Replies

0
Filling a form based on a Table

Gene--O

Total Posts

76

Likes

3

0
Gene--O
Good Afternoon,I have a 2 page form that I am creating.The first page is a timesheet. It has 2 fields of interest which are both repeated in a table with 15 rows:The first field is named "Date1". This field contains the day of the month (ex. 1, 2, 3...)form1.subform[1].Table1[0].Row1.Date1The second field is named "amIN". In this field, the employee will enter the time they started their shift. (ex. 08:00)form1.subform[1].Table1[0].Row1.amINThe second page will have fields where the employee wil...

Views

1.0K

Likes

0

Replies

2
Re: Hidden Subforms

Gene--O

Total Posts

76

Likes

3

0
Gene--O
Thank you so much Steve!!!!

Views

315

Likes

0

Replies

0
Re: Hidden Subforms

Gene--O

Total Posts

76

Likes

3

0
Gene--O
thanks for your reply, BUT, I'm not familiar with this at all. Can you give me an example of how to insert it into my script?thanks!

Views

307

Likes

0

Replies

0
Hidden Subforms

Gene--O

Total Posts

76

Likes

3

0
Gene--O
Good Afternoon All,I am not very familiar with subforms, so PLEASE help!I have created a file with a drop down box called "Applicant Type". There are 4 possible values in this box: "Individual" "Partnership" "Assocation" and "Corporation". I have created 4 subforms with corresponding names: "IndividualSub" "PartnerSub" "AssociationSub" "CorporationSub". All of these subforms are "hidden" in the Initialize Event of each one.I am trying to create a script that makes the appropriate subform become ...

Views

1.1K

Likes

0

Replies

4
Re: Currency Decimal Places

Gene--O

Total Posts

76

Likes

3

0
Gene--O
thank you thank you thank you thank you Francis!I tried (in vain) to get the round function to work before. You're answer was correct!have a wonderful day!Gene-O

Views

431

Likes

0

Replies

0
Re: Currency Decimal Places

Gene--O

Total Posts

76

Likes

3

0
Gene--O
Thanks for your reply!However, I cannot download the sample. I get a message that says the file is damaged and cannot be downloaded.Any other suggestions??Gene-O

Views

430

Likes

0

Replies

0
Currency Decimal Places

Gene--O

Total Posts

76

Likes

3

0
Gene--O
HELP!I have ready many posts on this subject, and can't figure out why mine won't work - it seems so simple:I have NumericField1 and NumericField2. I want to multipy the user entered value from NumericField1 by a fixed value (in this case .555) to return a currency rounded up to the nearest cent (hundredths decimal point). I have tried using the field pattern options, but NONE of them will round up, they just return a dollar value with 2 decimal places.For example:I enter "307" into NumericField...

Views

1.7K

Likes

0

Replies

6
Re: Disappearing Radio Button Selection

Gene--O

Total Posts

76

Likes

3

0
Gene--O
Bruce,I don't know how to publish it for you to look at. What would you like me to do? I appreciate the help!Gene-O

Views

301

Likes

0

Replies

0
Disappearing Radio Button Selection

Gene--O

Total Posts

76

Likes

3

0
Gene--O
I have created a dynamic form with 4 radio buttons. Each of these buttons makes a hidden subform appear. They work just fine. However, when I click on a radio button, the check mark, cross, etc. that marks the radio button appears breifly in the button but then disappears. The radio button still functions properly thought.anybody have any ideas?thanks so much!Gene-O

Views

752

Likes

0

Replies

2
Re: If/then statement with hidden fields

Gene--O

Total Posts

76

Likes

3

0
Gene--O
Jono - you are correct! When I saved it as dynamic, it worked. Thanks SOOOOOOO MUCH!

Views

2.7K

Likes

0

Replies

0
Re: If/then statement with hidden fields

Gene--O

Total Posts

76

Likes

3

0
Gene--O
No, it’s Static.Lt. Gene SchrieberAlabama Alcoholic Beverage Control BoardEnforcement District 1P.O. Box 1755Florence, Alabama 35631(256) 764-2435(256) 766-1793 Faxwww.abc.alabama.gov"Attitude is a choice"

Views

2.7K

Likes

0

Replies

0
Re: If/then statement with hidden fields

Gene--O

Total Posts

76

Likes

3

0
Gene--O
Thanks for the replies!!If I create a test form, these scripts work perfectly. For some reason, they won't work on the form I need them to.Any ideas?????thanks!!!

Views

2.7K

Likes

0

Replies

0
If/then statement with hidden fields

Gene--O

Total Posts

76

Likes

3

0
Gene--O
I have a form with a drop-down field that has 3 possible values (Today, Tommorrow, Next Week). Below this drop-down field is text field (TextField10) that needs to be filled out by the user ONLY if "Next Week" is selected in the drop-down. I would like for TextField10 to be hidden unless "Next Week" is selected. For TextField10, I have "this.presence="hidden" written into the initialize event so it is hidden when the user opens the form. This works.For the drop-down field, I have:if (this.rawVal...

Views

18.7K

Like

1

Replies

9
Re: Calculating times past midnight

Gene--O

Total Posts

76

Likes

3

0
Gene--O
You are AWESOME!Thank you so much for your patience and working this out for me!!!

Views

681

Likes

0

Replies

0
Re: Calculating times past midnight

Gene--O

Total Posts

76

Likes

3

0
Gene--O
I'm sorry, but the sample does not do what I need the form to do!Here is the script I have:var fullTime = 0var breakTime = 0if (amIN ne null and pmOUT ne null) then if (Time2Num(amIN.formattedValue, "HH:MM") lt Time2Num(pmOUT.formattedValue, "HH:MM")) then fullTime = Abs(Time2Num(amIN.formattedValue, "HH:MM") - Time2Num(pmOUT.formattedValue, "HH:MM")) / (60 * 60 * 1000) else fullTime = 24 - Abs(Time2Num(pmOUT.formattedValue, "HH:MM") - Time2Num(amIN.formattedValue, "HH:MM")) / (60 * 60 * 1000) e...

Views

653

Likes

0

Replies

0
Re: Calculating times past midnight

Gene--O

Total Posts

76

Likes

3

0
Gene--O
I apologize if I didn't make myself clear! I am just not familiar enough with scripting to know where to insert your script to make it work.Here is the latest script I have from you. WIll you please insert the addition to make it calculate amIN and amOUT if they are the only two entries? var fullTime = 0var breakTime = 0 if (amIN ne null and pmOUT ne null) then if (Time2Num(amIN.formattedValue, "HH:MM") lt Time2Num(pmOUT.formattedValue, "HH:MM")) then fullTime = Abs(Time2Num(amIN.formattedValue,...

Views

652

Likes

0

Replies

0
Re: Calculating times past midnight

Gene--O

Total Posts

76

Likes

3

0
Gene--O
Radzmar,I copy/pasted your script, and I can't get it to work. It calculates the total shift for all four fields, and it calculates past midnight, but I can't get it to calculate just the first two fields (amIN and amOUT) only. I pasted it into the calculate event in FormCalc.Any ideas?thanks so muchGene-O

Views

678

Likes

0

Replies

0
Re: Calculating times past midnight

Gene--O

Total Posts

76

Likes

3

0
Gene--O
Radzmar,Thanks so much this goes past midnight as promised. I have one more problem with it though....Sometimes, an employee may only work in the morning (8am until noon) and take the rest of the day off with no break. I need your script to calculate those hours as a total and not wait for all of the fields (amIN, amOUT, pmIN, pmOUT) to be filled before reaching a total hours. Here is the script again, just in case you need it for the field names: var fullTime = 0var breakTime = 0 if (amIN ne nu...

Views

676

Likes

0

Replies

0
Calculating times past midnight

Gene--O

Total Posts

76

Likes

3

0
Gene--O
Hello All,I am working on a timesheet for employees. It has 4 time fields (amIN, amOUT, pmIN, pmOUT) to allow for a lunch break. I have a script that calculates well for normal business hours. BUT, if the work shift goes past midnight, then it does not calculate correctly.Here is what I have in FormCalc in a calculate event:var fullTime = 0var breakTime = 0 if (pmIN ne null and pmOUT ne null) then if (Time2Num(amIN.formattedValue, "HH:MM") < Time2Num(pmOUT.formattedValue, "HH:MM")) then fullTime...

Views

8.1K

Likes

0

Replies

11
Re: Time calculations past midnight

Gene--O

Total Posts

76

Likes

3

0
Gene--O
Radzmar,I’m sorry to bother you again, BUT, I have run into a problem. In certain instances, the calculation does not handle crossing midnight well at all. I have attached a copy of the form so you can see the results.Please note on Thursday the 3rd, and Friday the 4th, I am getting a negative hour value return.Will you please help me again!Thanks!Lt. Gene SchrieberAlabama Alcoholic Beverage Control BoardEnforcement District 1P.O. Box 1755Florence, Alabama 35631(256) 764-2435(256) 766-1793 Faxww...

Views

331

Likes

0

Replies

0
Likes from