I am using VS2010 WebTest to inovoke a list of WCF operations in sequence.

First call is to obtain a session token from the server. This token has to be passed as request element to all subsequent calls. I have extracted this token and stored this into Context as MyToken.

enter image description here

I need your help to find out how to bind MyToken into subsequent xml requests.

Is there any directive like <%# %> for this purpose.

Thank you for your help.

有帮助吗?

解决方案

After a bit of more search, I have found out that we can use double curly braces to bind Context Parameters in string body of the request Xmls. As below -

{{MyToken}}

Visual Studio replaces these token in the XML Requests with values at runtime, dynamically.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top