You need to sign in to do that
Don't have an account?
micwa
QueryResult
Im new to .Net...
Isn't it possible to cast the QueryResult to an SObject where I can access the properties with dot notation instead of using case?
What I did
Is that the only possibility? I would like to have something like:
String accountName = item.Name;
Thanks for your help.
Isn't it possible to cast the QueryResult to an SObject where I can access the properties with dot notation instead of using case?
What I did
Code:
apex.QueryResult all = binding.query("Select a.Id, a.Name from Account"); foreach (var item in all.records) { foreach (XmlElement col in item.Any){ switch (col.LocalName.ToLower()) { case "id": //to something } } }
Is that the only possibility? I would like to have something like:
String accountName = item.Name;
Thanks for your help.
Superfell
You can do that if you use the enterprise WSDL instead of the partner WSDL.