Skip to Content
0
Former Member
Jul 29, 2009 at 02:51 AM

dynamically change the pattern of numeric field in adobe

800 Views

I am using a adobe form to display Sales order ouput.

I have a requirement that for some kind of sales order the quantity field should be displayed with 2 decimal places and for some with 4 decimal places.

So i have made the field in the form with display pattern = z,zzz,zzz,zz9.99

and writing a FromCalc script as below.

if ( z_mix eq "X" ) then

Format ("z,zzz,zzz,zz9.9999", data.MainSubform.ItemTable.ItemGroup.Items.KWMENG.value)

endif

i also tried

if ( z_mix eq "X" ) then

data.MainSubform.ItemTable.ItemGroup.Items.KWMENG.format = "z,zzz,zzz,zz9.99"

endif

The problem is i am not able to understand what statement to be used to change the format of a numeric field.

When i replace the second code with

data.MainSubform.ItemTable.ItemGroup.Items.KWMENG.presence = "hidden"

this functionality works. Which means i need to correct statement for pattern change of a numeric field.