Validation Help

I have a content type that contains a dropdown box and an editbox. The max number of characters allowed in the editbox depends on what option has been selected in the dropdown box.

So, for example, if the “Notice” option has been selected in the dropdown box, I’d like to display an error if the text in the editbox exceeds 110 characters, but if the user has selected “focus” then, I want to display an error if the content in the editbox exceeds 130 characters and so on.

Is this sort of validation possible? If it is, I’d be grateful if anyone could advise on how to do it.

Thanks in advance.
Tanya

Forgot to include the Rx version, it’s 6.5.2

Tanya,

Yes, you can do this by writing a custom field validation extension.

RLJII

[QUOTE=rljohnson;1267]Tanya,

Yes, you can do this by writing a custom field validation extension.

RLJII[/QUOTE]

Thanks for your reply. Do you know if there is any documentation or examples of how to go about doing this?

Thanks
Tanya

Tanya

For documentation on writing a field validation, see “Field Validations” on p. 15 of the Rhythmyx Technical Reference Manual.

I don’t know of any examples. Perhaps other posters to the forums could contact you with examples they have implemented.

RLJII

Hi

I’ve now created this custom validation rule and it’s all working. I did however spot something odd. When adding more than one validation condition to my control you cannot change the boolean value, it’s hardcoded as AND.

I’ve got around this by editing the content editor XML file in the ObjectStore.

Is this a known bug?

Cheers
James

It was not a known bug, but I’ve submitted one.