Quantcast
Channel: VMware Communities: Message List
Viewing all articles
Browse latest Browse all 252940

Re: Always DHCP gets assigned instead of Static ip pool in .net sdk 5.1

$
0
0

Thanks ChrisF. I tried your idea but did not work.

 

This is what I tried now and just now it worked.

VM vm = GetFirstVM(vcloudClient, CreatedBy);//vapp.GetChildrenVms().FirstOrDefault();

NetworkConnectionSectionType networkconnectionsectiontype = vm.GetNetworkConnectionSection();

networkconnectionsectiontype.NetworkConnection[0].IpAddressAllocationMode ="POOL";//IpAddressAllocationModeType.POOL.ToString();

networkconnectionsectiontype.NetworkConnection[0].network = vdc.GetAvailableNetworkRefs()[3].name;

vm.UpdateSection(networkconnectionsectiontype).WaitForTask(0);

 

 

 

 

 

 

 

This "IpAddressAllocationModeType.POOL.ToString()" is wrong and mislead me and have to figure out its just "POOL" by reverse engineering.

 

Hmm any way thanks Chris for taking your valuable time in answering. Appreciate it.

 

Now Connected is not checked need to see why? and also need to figure out how to assign network adapter type via .net SDK.

 

Sudheer


Viewing all articles
Browse latest Browse all 252940

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>