Level 1

0% to

Level 2

Tip /

to gain points, level up, and earn exciting badges like the new
Mission!

View all

Speich4fun
Offline

10

Accepted Solutions

Accepted Solutions
0

Likes

Likes
0

Posts

Posts
45

Discussions

Discussions
0

Questions

Questions
45

Ideas

Ideas
0

Blog Posts

Blog Posts
0
Sum fields based on dropdown field
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
Hey sorry I haven't touched this in awhile.I have an expense report and a dropdown for category. I need to then sum the expenses based on that dropdown.Something like:If ExpenseDesction[n] ="abc" or "bca" or "cba" thensum ExpenseAmount(n)Else sum ExpenseAmount(n)Seems super simple.

Views

233

Likes

0

Replies

1
Re: Adding values from mulitple arrays in a for loop with if then statement
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
Yes. There is the "Total" field which gets the \$=0 but I added "holiday" to total just holiday hours. So I took your formula and added a bunch elseif statements. I can post my final formula later as now I am out of the office. Best Regards,Benjamin Speich Customer Service SpecialistMentice Inc.Cell 312-504-8820

Views

293

Likes

0

Replies

0
Re: Adding values from mulitple arrays in a for loop with if then statement
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
Oh sorry yes. I guess i need to go get lunch. I have a "Total" column and then a a break out section of what the the hours are as monday can have 3 hours of Vacation and 5 hours of regular, so i just had to tweak the if statement and yes replace the \$=0 with what i wanted.

Views

219

Likes

0

Replies

0
Re: Adding values from mulitple arrays in a for loop with if then statement
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
So I have a Total Field that on the calculate event i have:Sum(Monday,Tuesday,Wednesday,Thursday,Friday,Saturday,Sunday)However when i add your if statement:if (Activity == "Holiday")then Holiday.rawValue = Sum(Monday,Tuesday,Wednesday,Thursday,Friday,Saturday,Sunday) else Holiday.rawValue = 0endifThe total field no longer totals anything UNLESS I choose holiday for the Activity field.... Any idea why that is?

Views

221

Likes

0

Replies

0
Re: Adding values from mulitple arrays in a for loop with if then statement
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
Thanks for your patience. Working pretty good now.

Views

218

Likes

0

Replies

0
Re: Adding values from mulitple arrays in a for loop with if then statement
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
So i switched to FormCalc and got this to workfor I=0 upto Activity.nodes.length - 1 step 2 doif (Activity[I] eq "Holiday") thenHolidayHours.rawValue = Monday[I] + Tuesday[I] etc...endifendforProbelm is I can't figure out in what even to place it so it is updated everytime the user edits any of the hours.

Views

219

Likes

0

Replies

0
Re: Adding values from mulitple arrays in a for loop with if then statement
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
The script is on the Calcuate event of the the "total" field so as the add hours on differnet days the total will change.So what i am trying to do is run through the different activity fields and find with column is "Holiday" if it happens to be Activity[5].rawValue = "Holiday" then I want the totals for Monday[5].rawValue, tuesday, wednesday etc.

Views

219

Likes

0

Replies

0
Adding values from mulitple arrays in a for loop with if then statement
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
So I have a table set up and need to add up the hours for specific activities.I have Activity() as an array of drop down boxes with things like "holiday, regular, vacation, etc"Monday(), Tuesday() etc, are numeric field arrays.and i am trying to popluation totals from the differnet Activities.Using Java like this and it doesn't seem to be working:for (var i = 0; i < 12; i++) { if (Activity[i].rawValue = "Holiday"){ \$.Value = Monday[i].value + Tuesday[i].value + Wednesday[i].value + Thursday[i].v...

Views

3.1K

Likes

0

Replies

10
Re: Populating days of the week from user Selected date. Timesheet style
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
This is definately a big help and on the right track. However I am having issues with the focus. If i choose NOT a monday i get stuck in a sort of loop with the message.I will keep trying to fix this, but my other option would be to create a dropdown box that is populated by all mondays for the current year. Anyone have any suggestions on that?

Views

182

Likes

0

Replies

0
Populating days of the week from user Selected date. Timesheet style
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
So I haven't touched Adobe or Java in over a year and am having trouble remembering a few things.I have a weekly timesheet I am editing and am having some issues.1. The User is to select the start date first, however i only want this to be a monday.2. This date will then populate the columns with the day and date in this format "Monday, Jan 9"For some reason I cannot get the fields to populate the way I want. Any help would be appreciated.

Views

1.4K

Likes

0

Replies

4
Re: Removing Specific Row from table
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
Ding Ding. Thanks a lot!

Views

78

Likes

0

Replies

0
Removing Specific Row from table
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
I have a table and a button with this codevar lastrow = Table1._Row1.count;if (lastrow < Units.rawValue) then while (lastrow < Units.rawValue) do Table1.Row1.instanceManager.addInstance() lastrow = lastrow + 1 endwhileelseif (lastrow > Units.rawValue) then while (lastrow > Units.rawValue) do Table1.Row1(lastrow).instanceManager.removeInstance() lastrow = lastrow - 1 endwhileendifHowever that line gives me an error. I am trying to remove the last line of the table. Any help?

Views

529

Likes

0

Replies

2
Re: Restrict Printing Until fields are full
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
Okay so this works, however. Now i am forgettting how to set Validation on a textbox. I don't care what they enter as long as it is not Null.Is there a way to have on the exit something likeIf (TextField1.rawvalue == Null) {TextField1.validate = False;}Something like that?I don't want the textfield to have a set pattern, just not Null

Views

454

Likes

0

Replies

0
Restrict Printing Until fields are full
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
I have form that i only want the user to be able to print if everything is filled out. Is there a code snippet someone can send me of a way to validate the fields and then enable printing. I know it could be in a button, but I want it to not allow them to simple got to File>Print. Like it would be password restricted until the fields were full.

Views

4.0K

Likes

0

Replies

5
Re: ListBox Select All
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
Perfect. The select all loop is what was looking for. I just wanted them to all be selected by default (almost). So this works. Now if it is wrong its because the user did something stupid. HAHAHAHAAnd yes they all show up now when I run the report.

Views

311

Likes

0

Replies

0
Re: ListBox Select All
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
Well i played with it a little more. Maybe i am not explaining correctly.My listbox is already being populated by other events. The user never has to actually select anything in the listbox. When i get the form back and export the data to a CSV file nothing from the listbox is being copied because nothing is selected. So i have to reopen the file select all and then save and then export again. But i have like 50-100 of these forms. So is there a way that when the user adds things to this box the...

Views

307

Likes

0

Replies

0
Re: ListBox Select All
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
Can you specify what "one" "two" three" are? Would they be specific to my form?

Views

311

Likes

0

Replies

0
Re: ListBox Select All
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
/* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-priority:99; mso-style-qformat:yes; mso-style-parent:""; mso-padding-alt:0in 5.4pt 0in 5.4pt; mso-para-margin:0in; mso-para-margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:11.0pt; font-family:"Calibri","sans-serif"; mso-ascii-font-family:Calibri; mso-ascii-theme-font:minor-latin; mso-fareast-font-family:"Times New Roman";...

Views

310

Likes

0

Replies

0
Re: ListBox Select All
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
Yes. I did. I can get it to work if I manual click and shift click the list, but I want it done automatically. Is there a way to have a button perform the select all? I have a button that adds items from several drop down menus to the box, I could just add it on the end of that one.Benjamin SpeichMobile: 312-504-88201-877-MENTICE

Views

300

Likes

0

Replies

0
ListBox Select All
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
How do I select all items in a list box.The box is being populated by other buttons. Then when i save the form and collect responses it only takes the item that is selected. So I need to have ALL selected by defualt.

Views

2.8K

Likes

0

Replies

13
Re: Collecting Responses
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
Okay so I am a moron. MConnection is one of my fields. IT'S default binding was set to normal. Everything else was set to none....so thats what default binding does huh?

Views

119

Likes

0

Replies

0
Re: Collecting Responses
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
I get file name, date collected, and MConnection....What is MConnection?

Views

131

Likes

0

Replies

0
Collecting Responses
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
I am having issues collecting my forms. I sent one out about 5 months ago and it work fine. When I open the response file i see all fields and am able to filter and sort them. But i just made a new form and it doesn't work. All i get is the form name and date. Did I miss click something? Please help I am having a lot of trouble with this.

Views

489

Likes

0

Replies

2
Check Box populating a ListBox
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
I have a form where a user check 1-4 options. these options tell me what they need for tools. "If checkbox 1 then bring (a,b,c)" So the problem is when someone check more then one box some of the tools overlap (e.g. Option 1 requires "a,b,c" Option 2 requires "a,d,e") So when they populate the list box how do I remove duplicates?

Views

378

Likes

0

Replies

0
Adding and Removing from Populated List Box
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
I have a drop down box with set values AND the ability to have user entered values. Upon selection or typing in i want them to click "ADD". Then it will populated a list box containing all of the things they entered. Then I also what them to be able to remove enteries with a button. Currently I can add, but no user entered data, and i can delete but only "on exit" which means they can select and click anywhere on the page, no button. Anyone have any suggestions. Even making the list box a dynami...

Views

391

Likes

0

Replies

0
Re: Removing Items from Populated List-Box
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
Thanks this seems to work. I put a dummy "remove" button next to it so people think to highlight and then click off.

Views

90

Likes

0

Replies

0
Re: Removing Items from Populated List-Box
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
How does the index be what is selected or clicked on?

Views

89

Likes

0

Replies

0
Re: Removing Items from Populated List-Box
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
I see the delteItem but I get an error wherever i put it. Am i using the wrong code: ListBox1.deleteItem

Views

96

Likes

0

Replies

0
Re: Removing Items from Populated List-Box
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun
also If i allow custom text in the drop down box. It adds each letter that i type. How do i only allow upon pressing enter or something

Views

88

Likes

0

Replies

0
Removing Items from Populated List-Box
Speich4fun
Level 3

Likes

0 likes

Total Posts

45 posts

0 solutions
View profile
Speich4fun