On Fri, Jan 25, 2013 at 8:58 AM, Staffan Tylen <firstname.lastname@example.org>
Well that makes a major difference. ;-)
Still what I said stands. You are making this too complicated. You don't want to use the returned message object, you want to use the dialog object you instantiated. Not only because trying to use the message object is too complicated, but also because it won't work.
I looked at the doc for the popup and popupAsChild methods and just added some clarifying text:
Note that the example shown below for the popup method makes use of the returned Message object to illustrate a possible use of the return. However, it is a contrived use case. Typically it is easier to just work with the instantiated dialog object directly. (In the case of the example this would be the dlg variable.)
One of the major problems I had with the original ooDialog documentation was that the return value from most methods was not documented. And the few times it was, it was often not documented correctly. So, when I began rewriting the docs one of the objectives was to always document what was returned. In the case of these 2 methods, I added an example that could show a possible use of the return. But, the example was not meant to imply that you should use the return.
In your case, what you want to do is invoke a method on the Dialog object. You can't do that by invoking a method on the Message object. But, it is very easy to invoke a method of the dialog object if you have a refence to it. ;-)