NetTalk Central
NetTalk Web Server => Web Server - Ask For Help => Topic started by: Nick LeForte on September 12, 2007, 02:16:05 PM
-
I'm having difficulty in implementing form radio controls.
I keep getting an error telling me that the field must be in the SP|RE|SS|ISO|PS|SV|D|3P|O
which are also my only radio selections on the form.
I put the results in i.e. 'SP' and SP with no luck.
The field in the dictionary is defined properly and works for standard applications, just not using NetTalk.
Can anyone help me??
Thanks,
Nick in Vancouver
-
Nick,
Some things that have bitten me with Radios -
Do you have the selections entered as strings in the Radio Options section of the fields template? And the values are quoted?
Is the field being updated the same size as the strings? - you are not putting 3 characters into a byte or string(2)
HTH,
chris c
-
Not sure what you mean entirely...
My field string is defined as string(20)
in the dictionary, my radio options are defined as shown above. This has always worked in a standard complied exe app.
I'm trying to duplicate the same function in NetTalk, I can't find a solution in any of the docs on how to implement a dictionary field with radio options. I tried selecting the field > selecting radio field type then enter the same names and options as defined in the dictionary. Doing this does not work. ???
Thanks,
-
Sounds like you're doing the same thing I am. except ...
I have the Send New Value to Server check box checked on the client side tab of the radio entry.
You might try that. I have it checked because I change stuff on the other tabs depending on what radio selection is made.
chris
-
The only solution so far was to remove the radio options from my dictionary. I then created the options within NetTalk and selected the Client Send to server check box as you suggested. This works but is not what I expected, I'd like to retain my options for the field in my dictionary for regular compiled versions of my application if I could.
Regards,
Nick
-
That's a little odd. I don't think the options from the dictionary are used in the netweb template at all. So my guess is that you only need the check box checked.
That being said, you could leave your dictionary choices as they were and use a local variable for the entry field and then set the table field during the validate.
chris
-
Hallo ,
>That's a little odd. I don't think the options from the dictionary are used in the netweb template at all.
In version 4.29 new future has been added:
Add: Dictionary validation (on the whole record) has been added to the ValidateRecord routine.
I have now the same problem with radio controls. In DCT I have a field STA:Status [string (10)] , Must be in list: Activ|Inactiv .
In a compiled exe works perfect. When I implement in NetTalk web, I set to radio then Text and Value to: 'Activ' & 'Activ' and 'Inactiv' & 'Inactiv' , after I compile and I insert new record , I check Active or Inactive , I always got error message:
''Status: Must be one of | '' ...... I don't know why ?? :( Someone has a solution ? :)
Thank you,
Robert
-
Exact problem I'm having, My solution was to remove the radio options altogether in the dictionary and set no validation on the field. I set it all within the NetTalk environment for now. Not a solution but a short gap work around...
Regards,
Nick
-
Hi Nick (and Robert),
Version 4.29 introduced dict field validation (ie code is generated that validates the field based on the rules in the dictionary as well as the rules you set on the Validation tab.
Alas I assumed (incorrectly) that the validation was case in-sensitive, and it's not. I've changed this for 4.30. Nick if you need an interim build send me an email and I'll send it to you.
Cheers
Bruce
-
Thanks Bruce, I can wait for the official release of 4.30 . I have it working for now as explained. I appreciate you offer however.
Thanks.