On Wed, Aug 13, 2008 at 12:33 PM, Mike Mabey <[EMAIL PROTECTED]> wrote: > On Wed, Aug 13, 2008 at 4:38 AM, Ed Leafe <[EMAIL PROTECTED]> wrote: >> >> >> I finally got a chance to test this, and my initial guess that >> addObject() wasn't properly updated was incorrect. Turns out that the >> call does indeed get resolved, so I'm wondering what exactly the error >> message you got was. Can you reproduce this and let me know? >> > > I'm not 100% sure this is the same error I was getting before, but when I > try to reference the .cdxml file like this: > > def onHit(self, evt): > absoludePath = "FileSelectDialog.cdxml" > frm = self.Form > dlg = dabo.ui.createForm(absoludePath, parent=frm) > dlg.show() > > I get a "File Not Found" error that reads "The file 'FileSelectDialog.cdxml' > cannot be found", and then the following traceback:
Dabo cannot find the file. It will try to intelligently guess where it is, but that doesn't mean it will find it. What does you directory structure look like? > > Traceback (most recent call last): > File "C:\src\dabo\ui\uiwx\dControlMixin.py", line 27, in _onWxHit > self.raiseEvent(dEvents.Hit, evt, *args, **kwargs) > File "C:\src\dabo\ui\uiwx\dPemMixin.py", line 925, in raiseEvent > super(dPemMixin, self).raiseEvent(eventClass, nativeEvent, *args, > **kwargs) > File "C:\src\dabo\lib\eventMixin.py", line 92, in raiseEvent > bindingFunction(event) > File "c:\docume~1\mike\locals~1\temp\tmpx2b1cb.py", line 559, in onHit > dlg.show() > AttributeError: 'NoneType' object has no attribute 'show' > This is a result of dabo not finding the file. If createForm can't find the file it will return None, and you are try to call the method show() on that None, so it throws an AttributeError because None doesn't have any methods. > But when I include the entire absolute path, I don't get any errors and the > dialog shows up just fine. Correct, because Dabo finds the file just fine. Nate L. _______________________________________________ Post Messages to: [email protected] Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users Searchable Archives: http://leafe.com/archives/search/dabo-users This message: http://leafe.com/archives/byMID/[EMAIL PROTECTED]
