Describes how to create a text object which displays a message or changes when certain conditions or selections are made on the Estimate or Work Order.

We want to add a message which appears when a part is selected showing the last date the Part was modified or Price Updated.

If the code is not entered correctly, you will get a detailed error message when you access the Product while Pricing or Estimating. Don't panic. Go back to the Pricing Form, clcik on the text item at fault and review the formula you have entered.

  1. Go to the Pricing Form where you want the message to appear and enter Edit mode. You will probably be looking at the Labels Tab. Click on the black Capital A, the Designer Label item. Then Click on your Pricing Form where you want this label and you will see a field appear saying something like “DesignerLabel12”. You can drag it around the form until it is where you want it. We often use the tdesignerpanel_pricing_form_objects which control its location to place it precisely. These are Top and Left. But be careful. If you enter a number which locates the Object off the form, your text object will disappear. If that happens, it can be relocated and restored but you will probably need Tech support for that.
  2. Enter a description or title in the Caption Property. This tells you what the text object will be reporting. We entered “Part Last Changed; 7/8/2009” as we want this object to report the Last Change Date for the part in the Part UDF “LastChanged.”
  3. In the Properties Column to the left locate the item saying Displayed Info. It will probably be set to pmdText. Click on that and you will see a list of selections. Select pmdFormula. You will probably have to use the Scroll Bar on the right of the list to scroll down to its location.
  4. When you select pmdFormula you will be presented with Cyrious's CFL Formula Builder. Now you enter the formula code which will cause the text variable to display the “Part Last Modified:….” message. Below in Item 6 is the code we entered. Note that you can use the complete array of functions, formulas, variables, etc. in your formulas, creating a limitless number of options for the kinds of “messages” you can print on your pricing form.
  5. Save your pricing form and test it with a new Order or Estimate.
IF ISASSIGNED(PartByVariableName("SubstrateThickness")) THEN
       IF DISPLAYDATE(PartUDFByVariableName("SubstrateThickness","LastChange",NODATE))  ""
               Then "Part Last Modified:  " + DISPLAYDATE(PartUDFByVariableName("SubstrateThickness","LastChange",NODATE))
      Else "" ENDIF
Else "" Endif
//The Part UDF containing the date of the last change is "LastChange"
//The Variable containing the part is SubstrateThickness

Contributor: Steve Gillispie

Date: 7/192009

Version: Control 43._

You could leave a comment if you were logged in.