Forum Discussion
Jul 17, 2012
Hi,
In looking at how you are calling the method, you are passing scalar values in while the parameters expect 1-d and 2-d arrays.
There's a whole bunch of PowerShell articles and examples I've written in the iControl wiki in the PowerShell topic:
https://devcentral.f5.com/wiki/iControl.PowerShell.ashx
I looked through there and there isn't an example that I've written on that page that says it creates a virtual server, but by going to the VirtualServer's create() wiki topic
https://devcentral.f5.com/wiki/iControl.LocalLB__VirtualServer__create.ashx
You can see at the bottom under the "Sample Code" section, there's one in there that uses that method.
https://devcentral.f5.com/wiki/iControl.PsProvisionVEForLocalDev.ashx
In that code, look in the "Create-Virtual" function and you'll see how I coded it.
Now, that method does create a http virtual, but you should be able to substitute the http profile for a tcp profile or something else that ties to your existing virtual server.
Hope this helps.
-Joe