Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I was wonderring if its possible to pass value from any selected listbox into the error message,
Currently I'm able to pass values dynamically from date listbox into the error message using
='Companydoes not have value for' & only(Date)
My requirement is the error message must be able to take values dynamically from any listbox that is selected
lets say I click on 2/2/2011
The message should say
" Company does not have data for 2/2/2011"
and if i click on listbox containing country names..
"" Company does not have data for China"
and if i click on listbox containing product names
"" Company does not have data for product name ".....so on ..
want to pass values dynamically from any selected list box into the error message
Thanks
Swarup
GetCurrentSelections() will give you a string with the current selections, also with fieldnames. You might format the string with optional delimiter and again parse it to get the details you want or just put in in your error message as is.
regards,
Stefan
GetCurrentSelections() will give you a string with the current selections, also with fieldnames. You might format the string with optional delimiter and again parse it to get the details you want or just put in in your error message as is.
regards,
Stefan
How do you format the string with delimiter?
From the help file:
Returns a string with the current selections in the document.
RecordSep is the separator to be put between field records. The default is <CR><LF>.
TagSep is the separator to be put between the field name tag and the field values. The default is ': '.
ValueSep is the separator to be put between field values. The default is ', '.
Maxvalues is the maximum number of field values to be individually listed. When a larger number of values is selected the format 'x of y values' will be used instead. The default is 6.
getcurrentselections ( )
getcurrentselections ( chr(13)&chr(10) , ' = ' )
getcurrentselections ( chr(13)&chr(10) , ' : ' , ' ; ' )
getcurrentselections ( chr(13)&chr(10) , ' : ' , ' ; ' , 10 )
You might then use e.g. TextBetween/ subfield / subfieldcount etc to parse the string.