Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / General MS InfoPath Questions / February 2006

Tip: Looking for answers? Try searching our database.

Conditonal Argument in a Form

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
tkozan@gmail.com - 03 Feb 2006 21:03 GMT
Hi Everyone,

I have a form with mutliple views. On each view is a check box that
needs to filled in order for that view to be complete and finished.

What I'd like to do is add a field or control that indicates all the
checkboxes across all the views are complete when all the checkboxes
are marked. Basically a control or field that says all checkboxes are
checked otherwise it is displayed as false.

This way i'll know that the form is complete and then i can pull this
control into a sharepoint form library view.

I've been playing around with the expression box and the conditional
formatting but haven't had any luck.

Ideas or suggestions welcome!

Thank you.

Todd
S.Y.M. Wong-A-Ton - 04 Feb 2006 20:07 GMT
What does your data source look like? Are the checkboxes in a group? If they
are, there might be an easier way to do it than what I'm going to describe
now.

I think a "trick" that I've successfully implemented several times could
work for your scenario. Try the following:

- Add a field called "helperField" of type Text (string) to your form.
- Add a rule to each one of the checkboxes in the views. This rule must have
2 actions:
1. Set a field's value: helperField = ""
2. Set a field's value: helperField = "check"
- Add a new checkbox to the form; we will call it "allCheckBoxesChecked" for
now. This checkbox will be checked when all the checkboxes in the views have
been checked.
- Create a rule on the "helperField" with an action that says:
Set a field's value: allCheckBoxesChecked = "FALSE"
- Add a condition to this rule ([Condition] button on "Rule" dialog box)
that checks whether any of the checkboxes have not been checked, i.e. have
value "FALSE". So the condition must look something like
checkbox1 = "FALSE" or checkbox2 = "FALSE" or .....
- Create a second rule on the "helperField" with an action that says:
Set a field's value: allCheckBoxesChecked = "TRUE"
- Add a condition to this rule that checks whether all the checkboxes have
been checked, i.e. have value "TRUE". So the condition must look something
like
checkbox1 = "TRUE" and checkbox2 = "TRUE" and ....

So now you have kind of an "intermediary" between the checkboxes in the
views and the allCheckboxesChecked field. This intermediary (=helperField)
will be triggered whenever the value of one of the checkboxes in the views
changes (checkbox is checked or unchecked) and then determine whether the
value of the allCheckboxesChecked field should be set to "TRUE" or "FALSE"
based on the values of all of the checkboxes in the views.

I've written this from the top of my head, so haven't tested it. You can try
it and see if it works.

---
S.Y.M. Wong-A-Ton

> Hi Everyone,
>
[quoted text clipped - 17 lines]
>
> Todd
Deborah Jean - 05 Feb 2006 16:53 GMT
Thanks for letting me steal another answer from you, when I start teaching it
this spring I'm sure you'll either have already answered all my questions or
I'll be bugging you alot.

Deborah Jean

> What does your data source look like? Are the checkboxes in a group? If they
> are, there might be an easier way to do it than what I'm going to describe
[quoted text clipped - 58 lines]
> >
> > Todd
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.