{"id":23194,"date":"2016-01-22T10:26:09","date_gmt":"2016-01-22T09:26:09","guid":{"rendered":"http:\/\/help.qualiware.it\/qw-help\/?p=23194&#038;lang=en"},"modified":"2018-04-11T11:41:16","modified_gmt":"2018-04-11T09:41:16","slug":"fd-form-object","status":"publish","type":"post","link":"https:\/\/help.qualiware.it\/qw-help\/fd-form-object\/?lang=en","title":{"rendered":"FORM OBJECT"},"content":{"rendered":"<h4 id=\"ipt_kb_toc_22812_1\" align=\"left\"><a name=\"progettazione_form_proprieta\"><\/a><span lang=\"en\">Description<\/span><\/h4>\n<div class=\"msgBody\">\n<p lang=\"en\">The Form is an object that contains other objects.<\/p>\n<\/div>\n<div class=\"msgBody\">\n<h4 id=\"ipt_kb_toc_22812_1\" align=\"left\"><a name=\"progettazione_form_proprieta\"><\/a><span lang=\"en\">Specific Properties<\/span><\/h4>\n<p lang=\"en\">In addition to <a href=\"http:\/\/help.qualiware.it\/qw-help\/fd-common-properties\/?lang=en\">common properties<\/a> contains the following properties:<\/p>\n<ul>\n<li><b><span lang=\"en\"><span style=\"color: #993300;\">Comments<\/span>:<\/span><br \/>\n<\/b><span lang=\"en\">visible only at design phase<em>, <\/em>allows information such as the description of the form itself, and change&#8217;s history.<\/span><\/li>\n<\/ul>\n<\/div>\n<h4 id=\"ipt_kb_toc_22812_2\" align=\"left\"><a name=\"eventi_form\"><\/a><span lang=\"en\">Specific events of the form<\/span><\/h4>\n<p lang=\"en\" align=\"left\">The main events on the form are:<\/p>\n<ul>\n<li><span lang=\"en\"><span style=\"color: #800000;\"> <b>ChangeformEvent<\/b><\/span>: this event is activated when changes the value of any form field. <\/span><span lang=\"en\">It can be used for example for<\/span><br \/>\n<span lang=\"en\"> \u2013 change the values of one or more fields based on the value entered in a field or more fields.<\/span><br \/>\n<span lang=\"en\"> \u2013 provide the user &#8220;warning messages&#8221; based on the value entered in a field or more fields.<\/span><\/li>\n<\/ul>\n<ul>\n<li><span lang=\"en\"><span style=\"color: #800000;\"> <b>LoadEvent<\/b><\/span>: event activated upon loading of a form (either existing or new).<br \/>\n<\/span><span lang=\"en\">It can be used for example to assign values to fields that do not correspond to fields in the database but are the combination of one or more of them (calculated fields).<\/span><\/li>\n<\/ul>\n<ul>\n<li><span lang=\"en\"><span style=\"color: #800000;\"> <b>SaveEvent<\/b><\/span>: event activated when you save the form.<br \/>\n<\/span><span lang=\"en\">It can be used to validate the data: you can indeed inhibit the save if the inserted data does not respect specific rules that can be placed in the event handling code, which must return a value of false if the save should be inibito.<br \/>\nFor more information about Events click&nbsp;<a href=\"http:\/\/help.qualiware.it\/qw-help\/events\/?lang=en\">here<\/a><\/span>.<\/li>\n<\/ul>\n<h4 id=\"ipt_kb_toc_22812_3\" align=\"left\"><a name=\"progettazione_form_proprieta\"><\/a><span lang=\"en\">Properties that can be used by code<\/span><\/h4>\n<div class=\"msgBody\">\n<h5 align=\"left\"><a name=\"progettazione_form_proprieta\"><\/a><span lang=\"en\">C\/S Properties<\/span><\/h5>\n<p lang=\"en\">None<\/p>\n<h5><a name=\"progettazione_form_proprieta\"><\/a><span lang=\"en\">Web properties<\/span><\/h5>\n<p lang=\"en\">None<\/p>\n<\/div>\n<h4 id=\"ipt_kb_toc_22812_4\" align=\"left\"><a name=\"eventi_form\"><\/a><span lang=\"en\">Methods that can be used by code<\/span><\/h4>\n<ul>\n<li lang=\"en\"><strong><span style=\"color: #993300;\">Alert (&#8220;message&#8221;)<\/span><\/strong>\u2014 displays a pop-up window that displays the string passed as parameter<\/li>\n<li lang=\"en\"><span style=\"color: #993300;\"><strong>GetAssigned (&lt;object&gt;)<\/strong>:<\/span> Returns <em>true<\/em> if the form object passed as a parameter only accepts values chosen from a list, and the value at the moment is chosen from the list, <em>false<\/em> otherwise.<\/li>\n<li lang=\"en\"><span style=\"color: #993300;\"><strong>IsNew (<span style=\"color: #993300;\">)<\/span><\/strong>:<\/span> Returns <em>true<\/em> if you are creating a new document\/form, <em>false<\/em> if the data is loaded by a document\/form previously saved<\/li>\n<li><span lang=\"en\"><span style=\"color: #993300;\"> <strong>SetAssigned (&lt;object&gt;,&lt;bool&gt;)<\/strong><\/span>: marks on the object passed in the first parameter as assigned if the second parameter is passed the value <em>true<\/em><\/span>.<\/li>\n<\/ul>\n<p>Only Form Designer Mobile:<\/p>\n<ul>\n<li><span style=\"color: #993300;\"><strong>AcquirePicture<\/strong><\/span>&nbsp;(<span style=\"color: #993300;\"><strong>&lt;postback button&gt;, &lt;type&gt;,&lt;file name&gt;<\/strong><\/span>): allows you to take a picture&nbsp;from the camera or from the gallery. The picture&nbsp;will be inserted into linked documents with the specified name.<br \/>\nIn the first parameter it&nbsp;can be passed a &#8220;Button object&#8221;, whose ClickEvent will be invoked at the picture confirmation. It could also be left to nothing if no postback is required.<br \/>\nIn the second parameter&nbsp;it must be specified the type of the picture:<br \/>\n1 = Low res picture<br \/>\n2 = Medium res picture<br \/>\n3 = High res picture<br \/>\n4 = Very high res picture<br \/>\n5 = Get picture from the gallery<br \/>\nIn the third parameter it can be optionally specified the name to be assigned to the picture, that will be shown in the linked document window. It can be left to nothing or empty string.<br \/>\n<span style=\"line-height: 1.5;\">Example of use (to be included in the &#8220;Click Event code&#8221; of a button):<\/span><\/p>\n<pre>form.AcquirePicture(form.findcontrol(\"POSTBACK\"),1,\"picture\")<\/pre>\n<\/li>\n<li><span style=\"color: #993300;\"><strong>AcquireSignature<\/strong><\/span> (<span style=\"color: #993300;\"><strong>&lt;postback button&gt;, &lt;default name&gt;<\/strong><\/span>): allows you to capture a handwritten signature by displaying the appropriate mask. The signature will be inserted into linked documents as image in Jpeg format.<br \/>\nBoth parameters could be left to nothing.<br \/>\nIn the first parameter it&nbsp;can be passed a &#8220;Button object&#8221;, whose ClickEvent will be invoked at the signature&#8217;s confirmation time.<br \/>\nIn the second parameter it can be passed the name of the person who will put the signature.<br \/>\nExample of use (to be included in the &#8220;Click Event code&#8221; of a button):<\/p>\n<pre>form.AcquireSignature(form.findcontrol(\"postback\"),\"Pier Alberto Guidotti\")<\/pre>\n<\/li>\n<\/ul>\n<pre>&nbsp;<\/pre>\n<p>It could also useful to read the following article:<\/p>\n<ul>\n<li><a lang=\"en\" href=\"http:\/\/help.qualiware.it\/qw-help\/fd-form-printing\/?lang=en\">FORM PRINTING<\/a><\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Description The Form is an object that contains other objects. Specific Properties In addition to common properties contains the following properties: Comments: visible only at design phase, allows information such as the description of the form itself, and change&#8217;s history. Specific events of the form The main events on the form are: ChangeformEvent: this event&hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"ngg_post_thumbnail":0,"footnotes":""},"categories":[56],"tags":[],"acf":[],"_links":{"self":[{"href":"https:\/\/help.qualiware.it\/qw-help\/wp-json\/wp\/v2\/posts\/23194"}],"collection":[{"href":"https:\/\/help.qualiware.it\/qw-help\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/help.qualiware.it\/qw-help\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/help.qualiware.it\/qw-help\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/help.qualiware.it\/qw-help\/wp-json\/wp\/v2\/comments?post=23194"}],"version-history":[{"count":0,"href":"https:\/\/help.qualiware.it\/qw-help\/wp-json\/wp\/v2\/posts\/23194\/revisions"}],"wp:attachment":[{"href":"https:\/\/help.qualiware.it\/qw-help\/wp-json\/wp\/v2\/media?parent=23194"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/help.qualiware.it\/qw-help\/wp-json\/wp\/v2\/categories?post=23194"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/help.qualiware.it\/qw-help\/wp-json\/wp\/v2\/tags?post=23194"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}