We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Object not set error in class

Hi, I've created a class around the datagrid. This class has methods around the datagrid, doing things like column formatting, giving new headertext on the columns and other things. On my PC, it works great. On a colleagues PC, the following line generates an error: Dim cm As CurrencyManager = CType(BindingContext(Me.DataSource, Me.DataMember), CurrencyManager) The error generated is an "Object not set....." error. when mousing over the line from my PC, the word "BindingContext" has a value of: {System.Windows.Forms.BindingContext}" on her PC, it has a value of Nothing. I'm sure this is the reason for the error, but I do not understand the behavior. Again, the code is wrapped within a class, and called using similar methods. Any ideas? Thanks Eddie

Loader.
Live Chat Icon For mobile
Up arrow icon