k-billy
10-30-2003, 09:23 AM
Hi,
I'm having a problem refreshing a view when the datapath it uses is changed.
I am using the datapath.setFromPointer() method to reset
the datapath each time on a class. The subviews/widgets of this class all have their 'ondata' methods called when I change the class' datapath. I am printing the widget's datapath when the ondata event is fired, and the datapath has been updated correctly. But the view itself is not updating. In fact, in some cases, it completely dissapears.
I have a couple of questions:
1. Is there a known bug with regards to a View refreshing when its datapath (or its parent view's datapath) is changed at runtime? If there is a bug, is there an accepatable workaround?
2. If there isn't a bug, Is there a correct way to dynamically modify a datapath object and have the view refresh? I have tried numerous approaches with inconsistent (and unsatisfactory) results:
-calling view.datapath.setXPath()
-calling view.setDatapath()
-calling view.datapath.setFromPointer(updatedDatapointer)
-manipulating the actual dataset, by removing the
original node that the view is pointing too, and inserting a new node.
Any input is greatly appreciated.
Caleb
I'm having a problem refreshing a view when the datapath it uses is changed.
I am using the datapath.setFromPointer() method to reset
the datapath each time on a class. The subviews/widgets of this class all have their 'ondata' methods called when I change the class' datapath. I am printing the widget's datapath when the ondata event is fired, and the datapath has been updated correctly. But the view itself is not updating. In fact, in some cases, it completely dissapears.
I have a couple of questions:
1. Is there a known bug with regards to a View refreshing when its datapath (or its parent view's datapath) is changed at runtime? If there is a bug, is there an accepatable workaround?
2. If there isn't a bug, Is there a correct way to dynamically modify a datapath object and have the view refresh? I have tried numerous approaches with inconsistent (and unsatisfactory) results:
-calling view.datapath.setXPath()
-calling view.setDatapath()
-calling view.datapath.setFromPointer(updatedDatapointer)
-manipulating the actual dataset, by removing the
original node that the view is pointing too, and inserting a new node.
Any input is greatly appreciated.
Caleb