on 04-09-2008 11:43 AM
Hi All,
I have one issue with the User-Defined Fields window of the ACTIVITY form.
I had added some user defined fields (UDF) to the Activities so that the User-Defined Fields are displaying in a separate window just near to the Activity window with Type (-651). All the UDFs are bound to the table, "OCLG".
I want to initialize the values in the User defined fields controls with a text when the form is loading.
I had tried to do this using
oForm.Datasources.DBDatasources.Item("OCLG").SetValue("U_CUST",0,"MyValue");When I executed this statement, i am getting HResult error.
Then I tried this by using UserDataSources.
The same error repeats.
But the code with .Specific.String = NewVal is working fine.
Can you please explain the scenarios that we are able to do it using .Specifc.String. Is this a true method for doing this?
if not
please tell me How can we do this using Datasources (DBDatasources/ UserDataSources),?
Please Help.
Thank you in Advance
Anoop
Anoop,
when you have created UDF in master item data, the textbox you can see on left side of form (separate form) is bounded already to this field. You cannot rebound it (its system form).
When you want to change the value, you must use specific.string or specific.value for that textbox (as you wrote), but the calcualted value will be stored into master table (change of udf will set formmode to update mode). If you dont need to update formmode, set the formmode by code to normal mode.
hope it helps
Petr
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
98 | |
12 | |
10 | |
6 | |
6 | |
4 | |
3 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.