For gods sake, what a stupid typo. :smileyblush: Thank you for your help. Now I get with this code:
my $vms = Vim::find_entity_views(view_type => 'VirtualMachine', properties => ['summar...
See more...
For gods sake, what a stupid typo. :smileyblush: Thank you for your help. Now I get with this code:
my $vms = Vim::find_entity_views(view_type => 'VirtualMachine', properties => ['summary.customValue','name',], );
for my $vm (@$vms) {
my $cv_ref = $vm->{'summary.customValue'};
next unless defined($vm->{'summary.customValue'});
print $vm->name . "\n";
for (@$cv_ref) {
next unless defined $_->value;
print "key: ",$_->key,"\tvalue: ",$_->value,"\n";
}
}
This output:
./SnapshotReminder.pl --url https://<fqdn>/sdk/webService
Enter username: *********
Enter password:
UHRZ-Ubuntu-E01
key: 2006 value: joerg.kastning@uni-bielefeld.de
In line number 5, is 2006 a unique value for the custom field? Is it possible to get the current name of the custom field instead of the id? Thanks a lot for your help and your patience with me.