SEARCH & SELECT VISUAL ASSIST ON CONTROLS WITH DIF
SEARCH & SELECT VISUAL ASSIST ON CONTROLS WITH DIFFERENT DATA TYPE
==================================================================
Under B7321 you can define on a string data type control (in FDA) a visual assist form returning with a numeric value.
It works fine.
Under B7331 the visual assist form can call up but the selected value will not appear in the control.
The keys of the resolution are some new feature in B7331 like:
- Visual Assist Button Clicked event
- Post Visual Assist Button Clicked event
- Suppress Default Visual Assist Form system function
You have to write some ER for Visual Assist Button Clicked. Her is an example:
=======================================================================
FORM: Sales Order Header [FIX INSPECT] (W4210G)
=======================================================================
CONTROL: EDIT Ordered By
EVENT: Visual Assist Button Clicked
-----------------------------------------------------------------------
evt_mnAddressNumber_AN8
0001 // *** Begins SAR#: GYZB7332, by Z. Gyimesi 05.30.2000
0002 //
0003 Suppress Default Visual Assist Form
0004 Call( App
0101S , Form: W0101SA )
VA evt_mnAddressNumber_AN8 <- AddressNumber
"XJDE0001" X Version
0005 //
0006 If VA evt_mnAddressNumber_AN8 is not equal to <Blank>
And VA evt_mnAddressNumber_AN8 is not equal to <Null>
And VA evt_mnAddressNumber_AN8 is not equal to <Zero>
0007 FC Ordered By = [VA evt_mnAddressNumber_AN8]
0008 End If
0009 //
0010 // *** Ends SAR#: GYZB7332, by Z. Gyimesi 05.30.2000
=======================================================================
Some explanation:
- you can define any form for the control making available the visual assist button for it (when it has not one default from Data Dictionary)
- you have to define an ER scope variable (e.g. evt_mnAddressNumber_AN8) with a data type like the return value of the called form getting the return value from it through the form interconnect data structure of it.
- Put the return value into form control in the assigment statement via "expression" instead of simple way. The purpose of it is the data type conversion.
(I tried these only with string controls with assist forms returning with a math numeric value.)
B7332 SP11, ESU 4116422, Intel NT4, SQL 7 SP1
(working with B7321, B7331, XE too)