jpoe Posted May 5, 2011 Share Posted May 5, 2011 Is it possible to change(or blank out) the contents of an input data field? I have a text block for an address that includes an optional endorsement line for postal presorting. Depending on the value of another input field I want to "blank out" the contents of the endorsement field. I have tried the following but it does not work. Using the OnRecordStart callback rule: if (Field("source") != 'REG') { Field("endorse") == ' ' Field("breakmark") == ' ' Field("im_bar") == ' ' } Any ideas? Link to comment Share on other sites More sharing options...
Dan Korn Posted May 5, 2011 Share Posted May 5, 2011 You can create a rule with the same name as a field, which will override the field's value, so that the Text Editor picks up the rule's value instead. So, for instance, you can create a rule named "endorse" and, in it, return either the field value or an empty string. And likewise for each field you want to override. This will work in any version of FusionPro. Depending on the version of FusionPro you're using, you might also be able to use the FusionPro.Composition.AddVariable() function in OnRecordStart, like so: FusionPro.Composition.AddVariable("endorse", "");Again, though, whether you can do that depends on the version you're using. The other solution, creating a rule for each field you want to override, will work in any version. Link to comment Share on other sites More sharing options...
jpoe Posted May 5, 2011 Author Share Posted May 5, 2011 Worked like a charm Dan. Thanks! I'm using a demo version 7.1P1c. Waiting on our payment to clear and will download FushionPro Direct. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.