Consultor Eletrônico



Kbase P105676: How to specify fields to be used for the filter in Dynamics Web User Interface
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   6/24/2005
Status: Unverified

GOAL:

How to specify fields to be used for the filter in Dynamics Web User Interface

GOAL:

How to limit the number of fields being used when filtering the data in SDO in Dynamics Web UI

FACT(s) (Environment):

Dynamics 2.1A
Dynamics 2.1B

FIX:

1. Create a javascript file and call it with the name of the container where
you want to have this behavior, e.g. 'mytest.js'
2. Place the following code in that file:
function yoursdoname_view() {
var myH=_yoursdoname.hdata;
var n=myH.fieldn;
for(var i=n-1;i>0;i--)
{
myH.fieldfilter[i]='n';
if(myH.fieldname[i]=='customer_code') myH.fieldfilter[i]='y';
if(myH.fieldname[i]=='customer_name') myH.fieldfilter[i]='y';
if(myH.fieldname[i]=='customer_discount') myH.fieldfilter[i]='y';
}
}
3. Make sure that you change the string 'yoursdoname' with the
name of the sdo that you are using and to change field names to
those that you want to use in the filter.
4. Open your container object and in the property sheet
locate the 'JavaScriptFile' and set it to the 'mytest.js' (without quotes).
After that save the container.
5. Copy the 'mytest.js' file into the 'dhtml' directory under the Dynamics
virtual directory you have created on your web server.
6. Start the browser and test your filter in the container: only
fields that you have chosen will appear in the filter dialog box.