Adjust Field Size from Script
17753
Question / Problem:
Is it Possible to Adjust Field Size Using KTM Scripting?
Answer / Solution:
The following code shows how to enlarge a field when a button is clicked in the validation form.
Private Sub ValidationForm_ButtonClicked(ByVal ButtonName As String, ByVal pXDoc As CASCADELib.CscXDocument) Select Case ButtonName Case "Button0" pXDoc.Fields(0).Width = pXDoc.Fields(0).Width + 10 pXDoc.Fields(0).Height = pXDoc.Fields(0).Height + 10 ' If you include the following line, you have a visible update, ' but the validation form flickers. ' If you exlude it, you see the changes only after switiching to ' a different document and back ' pXDoc.Reclassify(pXDoc.ExtractionClass) ' ValidationForm.MiniViewers.ItemByName(pXDoc.Fields(0).Name).Refresh End Select End Sub
Applies to:
Product | Version | Category |
---|---|---|
KTM | 6.3 | Scripting |
KTM | 6.2 | Scripting |