The issue you have is that Currency, which is the data type for
fromCurrency and toCurrency is an enumerated data type.
There is a issue with CF/Axis and enumerated types. I believe that
Macromedia is aware of it, but have no idea what the status is or if
there is a decent work around.
I've been trying to sort out an issue with an enumerated data type on a
web service I'm trying to access and as yet I haven't had been able to
get a solution, other than to hard/hand code the soap packet and pass it
via cfhttp to the webservice. Not a usable solution unfortunately.
The other solution that someone suggested was to import the web service
and rewrite it to accept strings/numerics and post it out to the actual
web service (I think I got that right). Again not really a usable
solution. Why should you have to rewrite someone else's web service... :o{
If get a sensible solution, I would love to know!
Regards
Stephen
Mike Kear wrote:
> I want to consume a web service for converting currencies (at
> http://www.webservicex.net/CurrencyConvertor.asmx?wsdl ) and I used the
> EXCELLENT implementation in DreamweaverMX to write the code. That drag and
> drop is an absolute gem for this!
>
> Anyway, the resulting page give an error and I cant see why because what's
> going in seems perfectly logical for what the web service is supposed to do.
>
>
> Here's the code that Dreamweaver wrote:
>
> <cfinvoke
>
> webservice="http://www.webservicex.net/CurrencyConvertor.asmx?WSDL"
>
> method="conversionRate"
>
> returnvariable="conversionRateRet">
>
> <cfinvokeargument name="fromCurrency" value="GBP"/>
>
> <cfinvokeargument name="toCurrency" value="USD"/>
>
> </cfinvoke>
>
> Which (I thought) should take the input value GBP and work out a conversion
> to USD, and return a variable #conversionRateRet# which will be a number
> such as 1.02, being the conversion rate.
>
> However here's what I get:
>
> [quote]
>
> Could not perform web service invocation "conversionRate" because
> java.lang.IllegalArgumentException: argument type mismatch
>
> [/quote]
>
> And it's highlighting the "toCurrency" line as the one with the error. Huh?
> If the 'fromCurrency" line is correct, how come the next line isn't? Can
> anyone see what's wrong? Or is there something else I have to do on the
> page?
>
> Cheers
>
> Mike Kear
>
> Windsor, NSW, Australia
>
> AFP Webworks
>
> http://afpwebworks.com
>
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

