Hi,

On 05.07.2007, at 14:56, Jean-François Veillette wrote:

from your description, it look like 'formValues()' wrap all values in
an array (from the doc).
        formValues()
                Returns an NSDictionary containing all of the form data
                with names for keys and NSArrays containing the value(s)
                associated with those keys for values.
so to get "value1", you would do :
String value1 = (String) request().formValues().valueForKey ("key1").objectAtIndex(0);

Or simply use 'formValueForKey':
String value1 = (String) request().formValueForKey("key1");

Thanx for the helpful hint :)

Regards,
Edgar

Le 07-07-05 à 06:33, Edgar Ra. Klein a écrit :

Hi guys,

I'm having a problem w/ the Dictionary returned by the DirectAction's form values. More precisely, I have a DirectAction w/ some form values like:
...DirectAction.woa/wa/default?key1=value1&key2=value2

The method request().formValues() returns an NSDictionary looking like that:
{key1 = ("value1"); key2 = ("value2"); }

Unfortunately, the values are wrapped into (" ") and therefore I cannot pass this dictionary to ask the EOUtilities.objectsMatchingValues method for database entries.

Am I doing s.th. wrong or is there an easy way to convert the wrapped values to unwrapped versions?

Thanx,
Edgar
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/ jean_francois_veillette%40yahoo.ca

This email sent to [EMAIL PROTECTED]

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to