PoeticAudio
asked on
I don't quite understand why this code works... simple, but I just don't get it.
I don't understand why you can cast a CurrencyManager as a DataView.
int rowCount = (currManager as DataView).Count;
I don't see how that works, but it does. I know this is really simple, but looking at the class heirarchy for these objects, it just doesn't make sense to me.
int rowCount = (currManager as DataView).Count;
I don't see how that works, but it does. I know this is really simple, but looking at the class heirarchy for these objects, it just doesn't make sense to me.
I neither understand why it works for you.
I get a compile-time error in Visual Studio 2005:
Cannot convert type 'System.Windows.Forms.Curr encyManage r' to 'System.Data.DataView' via a built-in conversion
I get a compile-time error in Visual Studio 2005:
Cannot convert type 'System.Windows.Forms.Curr
ASKER
read my second post
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
ahh. Okay. Thanks man!
ASKER
It's the CurrencyManager.List that casts, but I still don't get it.
int rowCount = (currManager.List as DataView).Count;