Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Setting "sap-client" parameter in <mx:HTTPService> object

GrahamRobbo
Active Contributor
0 Kudos

Hi there,

I am having problems setting the "sap-client" parameter on a HTTPService object due to the "-" in the parameter name.

If I do it like...

<mx:HTTPService id="vmsplan" url="http://mysaphost.domain.com/sap/bc/bsp/sap/yvms1/vmsdata.xml">
	<mx:request>
		<sap-client>410</sap-client>
	</mx:request>
</mx:HTTPService>

... I get the compile time error

"1084: Syntax error: expecting colon before minus"

If I do it in ActionScript like this...

				var parameters:Object = new Object;
				parameters.sap-client = "410";
				vmsplan.request = parameters;

...the compile time error is...

"1050: Cannot assign to a non-reference value."

Can anyone help me with this one?

Thanks

Graham Robbo

1 ACCEPTED SOLUTION

former_member10945
Contributor
0 Kudos

Without running it you should be able to do the actionscript one like this:

parameters["sap-client"] = 4.10;

Object type objects in the actionscript sense are dynamic and you can think of their properties as nothing more then a dictionary which you can edit freely.

2 REPLIES 2

former_member10945
Contributor
0 Kudos

Without running it you should be able to do the actionscript one like this:

parameters["sap-client"] = 4.10;

Object type objects in the actionscript sense are dynamic and you can think of their properties as nothing more then a dictionary which you can edit freely.

0 Kudos

Thanks Dan, worked a treat!