using System;
using Silk Performer;
namespace SPProject1
{
[VirtualUser("VUser")]
public class VUser
{
public localhost.Service1 mService;
public VUser()
{
}
[Transaction(ETransactionType.TRANSTYPE_INIT)]
public void TInit()
{
mService = new localhost.Service1();
}
[Transaction(ETransactionType.TRANSTYPE_MAIN)]
public void TMain()
{
int nRetParam = mService.ServiceCall1("Testparam");
Bdl.Print("Return value of ServiceCall1: " +
nRetParam.ToString());
mService.ServiceCall2(nRetParam);
}
[Transaction(ETransactionType.TRANSTYPE_END)]
public void TEnd()
{
}
}
}
Initiate a Try Script run by calling Silk Performer/Try Script or by pressing the F8 key.The return value is output into the Virtual User Output Window via the Bdl.Print method.
In the TrueLog, two nodes in the main transaction represent the SOAP HTTP traffic that was responsible for the Web service calls. By default all HTTP traffic is redirected over the Silk Performer Web Engine; therefore output is available in the TrueLog. You can turn off redirection or enable it for specific Web service client proxy classes using the Web Settings dialog.