I have a customer report of an IndexOutOfRangeException but the line number at which it is reported has no array access! The line is of the form:
using (XyzConnection conn = new XyzConnection(anObject.aProperty.anotherProperty))
XyzConnection, anObject, etc are made up replaced names but the construct is essentially same.
Can the above itself throw IndexOutOfRangeException?
Is it possible that the array access (and exception) are in some code called from above line, i.e. the constructor or one of the property getters? How can I identify the correct location?
I should mention that the problem cannot be reproduced in development environment and I cannot install Visual Studio on the customer's machine.