View comments | RSS feed
Contents > CFML Reference > ColdFusion Tags > cfinvokeargument PreviousNext

cfinvokeargument

Passes the name and value of a parameter to a component method or a web service. This tag is used within the cfinvoke tag.

Extensibility tags

<cfinvokeargument
name="argument name"
value="argument value">

cfargument, cfcomponent, cffunction, cfinvoke, cfobject, cfproperty, cfreturn

ColdFusion MX: Added this tag.

Attribute

Req/Opt

Default

Description

name

Required

 

Argument name

value

Required

 

Argument value

You can have multiple cfinvokeargument tags in a cfinvoke tag body.

You can use cfinvokeargument tag to dynamically determine the arguments to be passed. For example, you can use conditional processing to determine the argument name, or you can use a cfif tag to determine whether to execute the cfinvokeargument tag.

1

<cfinvoke 
   component="nasdaq.quote" 
   method="getLastTradePrice"
   returnVariable="res">
   <cfinvokeargument 
      name="symbol" value="mot">
   <cfinvokeargument 
      name="symbol"    value="macr">
</cfinvoke>

<cfoutput>#res#</cfoutput>

2

<cfinvoke
   webservice ="http://www.xmethods.net/sd/2001/BabelFishService.wsdl"
   method ="BabelFish"
   returnVariable = "varName"
   >
   <cfinvokeargument 
      name="translationmode" value="en_es">
   <cfinvokeargument 
      name="sourcedata" value="Hello world, friend">
</cfinvoke>
<cfoutput>#varName#</cfoutput>   

Contents > CFML Reference > ColdFusion Tags > cfinvokeargument PreviousNext

ColdFusion 8 | ColdFusion MX 7 | ColdFusion MX 6.1 | ColdFusion MX | Forums | Developer Center | Bug Reporting

Version 6.1

Comments are no longer accepted for ColdFusion MX 6.1. ColdFusion 8 is the current version.

Comments


No screen name said on Jan 20, 2004 at 3:02 PM :
How do you pass a numeric value with cfinvokeargument ? I need to pass a numeric value to a web service.
No screen name said on Nov 15, 2004 at 4:35 PM :
"Should" the <cfinvokeargument> have a closing </cfinvokeargument> tag or should it be a self-closing tag i.e. <cfinvokeargument />? Or does it not require to be closed?

 

RSS feed | Send me an e-mail when comments are added to this page | Comment Report

Current page: http://livedocs.adobe.com/coldfusion/6.1/htmldocs/tags-p68.htm