Forum Discussion
JT_47697
Nimbostratus
Feb 13, 2009Simple C# Examples Please
Guys,
I've written a few C apps but I'm still learning. I just downloaded IControl Assembly in hopes of writing a simple app that monitors member states - i.e. I want to know if a node drops out of a pool indicating a problem host.
The Visual Studio Quick Start guides say that three lines of code are all that's needed to access the thousands of methods in the API. Yet, I haven't seen a single example with those three lines of code in them. The only two examples provided in the SDK (DistributionMonitor and CSSamples) were auto created by wsdl and reference all the soap calls you said are no longer needed.
I even watched a video (I can't remember the name but it's the one that required some debugging) and one of the methods used required another method. Where is that documented? I've tried the WIKI and the SDK information but there's no C examples or requirements out there.
Please note that your audience is typically networking folk and although we're getting better at writing code for our own purposes, it would be nice to have some single purpose samples that we can put together to our liking.
Again, I'm not a newbe at development but it would sure help if there were some better documentation on the API with some examples to really get us started.
thanks,
John
- Sorry for the confusion John. I guess I'll need to get around to updating all the samples in the SDK to use the iControl Assembly.
public void GetPools(String bigip, String username, String password) { iControl.Interfaces m_interfaces = new iControl.Interfaces(); if ( m_interfaces.initialize(bigip_address, 443, username, password) ) { String [] pool_list = m_interfaces.LocalLBPool.get_list(); Console.WriteLine("Available Pools..."); for(int i=0; i { Console.WriteLine("[{0}] : {1}", i, pool_list[ i ]); } } }
- JT_47697
Nimbostratus
Thanks Joe, - I've been doing the iControl thing since day 1 of it's existence so I've got a little bit of time on you. Keep it up, it's really not that hard. B-).
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects