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

VMWare VIM SDK .Net, update CustomFieldValue

$
0
0

Hi,

 

I am not sure if this is the correct forum for SDK questions, please redirect me to a correct one if not, but here goes:

 

I have this code:

 

 

 

public void SetFieldValue(int key, string value)

{

    var customField = (CustomFieldStringValue)this.VirtualMachine.CustomValue.Single(cv => cv.Key == key);

 

 

    customField.Value = value;

}

 

 

 

That in itself works, as in, it's visible that the value has changed, but I don't see it reflected upon the actual custom field on the VM when viewed in the vSphere Client.

So, is there a save I need to do, or do I have to change the value in another fashion?

 

Thanks


Viewing all articles
Browse latest Browse all 230200

Trending Articles



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