BindingNavigator Control Disabled

xiecsuk

Member
Joined
Apr 24, 2005
Messages
23
Location
Coventry, Warwickshire, UK
Programming Experience
10+
I have included a BindingNavigator control on a Windows form that has text boxes displaying the contents of an XML file. The XML file has been read into an in-memory table using DOM as an XmlDocument object. It is not bound to the BindingNavigator control. When I display the form, the BindingNavigator control is disabled, although it is displaying 1 of 11 correctly. Help text suggests that it is possible to use a BindingNavigator control without it being bound, so does anyone have any suggestions as to why it is disabled. It is shown as Enabled = True when I look at its properties in Design mode.

Thanks
 
I'm going to guess that if you don't use a BindingSource then you'd need to set the BindingContext property explicitly. There has to be some sort of binding going on, as the name "BindingNavigator" suggests. Note also that the BindingNavigator is simply a specialised ToolStrip. If you don't want to use bind anything then just create your own ToolStrip with the functionality you do want.
 
Thanks for that. It was my first thought too, but as I said in my original post, the help text suggests that it should be possible to use it without a binding.

Do you have any suggestions on how to bind the XmlDocument object to the BindingNavigator? I have tried using the wizard to bind an object and then selected the XmlDocument object, but it doesn't seem to hold the binding. Should I be using XPath or XML serialisation for it to work?

Thanks
 
Back
Top