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 / August 2005

Tip: Looking for answers? Try searching our database.

Disable Submit in infopath

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
JoeAtPMHCC - 04 Aug 2005 21:04 GMT
Is there a way to prevent to disable the submit button based upon the value
of a certain field?  In my app data is populating the form from a variety of
sources, so the form seems 'edited' to infopath even though the user either
has no enterable fields or has done nothing interactive.  I would really like
to know how to programatically control the enable/disable submit options.
Scott L. Heim [MSFT] - 04 Aug 2005 21:49 GMT
Hi Joe,

If you only have a small number of fields that you want to be sure are
completed, you can add a button to your form with a "Rule" to execute the
submit. The rule you create would have a condition applied so it would only
execute based on the condition being true.

If there are a number of fields you want to insure are completed, you can
still use the button but you would need to write some custom script to
"test" each field to insure they are completed as you need. Once they are,
you would simply call the "submit" method:

    XDocument.Submit();

Lastly, if you use a button to execute the submit via a rule or custom
code, you can remove the "submit" functionality from the menu/toolbar by
disabling this option under Tools->Submitting Forms.

I hope this helps!

Scott L. Heim
Microsoft Developer Support

This posting is provided "AS IS" with no warranties, and confers no rights
JoeAtPMHCC - 05 Aug 2005 14:10 GMT
Thank you very much for your fast response!
This does help, but I guess there is no way to use code to functionally
execute
the options under Tools->Submitting Forms?
This would be a big help in my case since this is one of many forms withing
my app
and I'd rather not have buttons or a different UI for only one form.
Thanks again,
Joe

> Hi Joe,
>
[quoted text clipped - 20 lines]
>
> This posting is provided "AS IS" with no warranties, and confers no rights
Scott L. Heim [MSFT] - 05 Aug 2005 16:12 GMT
Hi Joe,

Correct - there is really not a method to control this at "runtime" (i.e.
turn this on or off) other than a process like what I previously described.

Best regards,

Scott L. Heim
Microsoft Developer Support

This posting is provided "AS IS" with no warranties, and confers no rights
 
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.