Author: jaydpatherbp | Posted on: 2/2/2010 11:44:02 AM | Views : 263

I am getting a strange compile error: cannot cast from type xxxx to XXXX, where XXXX is my class name, and xxxx is my class name with all uppercase characters converted to lowercase.
I have a UserControl in one of my pages that has to be added at runtime, since I don't know how many instances of the control should be on the page until runtime.  I have a class-level variable that is an array of these controls.  This variable declaration is where my compile error happens:
protected bManage_Contracts_ContractLineItems_ContractLineItemControls_MultiSelectCalendarCtrl[] _arrCalendarControls = null;
This compiles on my development machine, but not on a different server.  On the server I get the error "Could not cast object from type bmanage_contracts_contractlineitems_contractlineitemcontrols_multiselectcalendarctrl to bManage_Contracts_ContractLineItems_ContractLineItemControls_MultiSelectCalendarCtrl."
I have seen this error on m ...

Go to the complete details ...