Hi all,
I have a report created via Infopath 2003 with some Text Boxes that have the "Cannot be blank" boxes checked (I have even added some data validation that stated if the field is blank then show an error alert). However, when I send the form I just receive a message that states: "This form contain validation errors. Errors are marked with either a red asterisk (required fields) or a red, dashed border (invalid values). Do you still want to send it? Yes No"
I don't want the user to have the 'yes' or 'no' option.
I have two levels of submitting.
1) A 'Submit' button with code to bring up an Outlook style envelope. (ctlSubmit function)
2) In that envelope is a 'Send' button beside the 'To' field.
After step 2 is when I'm receiving the message.
How can I make it so that the user must fill in the required fields? Any help is greatly appreciated.
This is my 'Submit' button code:
function ctlSubmit::OnClick(eventObj)
{
try
{
var oEnvelope = Application.ActiveWindow.MailEnvelope;
var objReport = XDocument.DOM.selectSingleNode("//my:myFields/my:report_name_blank");
//var objRequestor = XDocument.DOM.selectSingleNode("/my:myFields/my:Request_By");
oEnvelope.Subject = "Data Request - " + objReport.text;
oEnvelope.To = "[email protected]"
oEnvelope.Visible = true;
}
catch(ex)
{
XDocument.UI.Alert(ex.description);
}
}