Ed Leafe wrote:
> On Apr 19, 2007, at 8:47 PM, Carl Karsten wrote:
> 
>> Those all seem to bind to self.something, which I don't think helps  
>> with the
>> cdxml.  maybe Demo needs a cdxml example, with a very basic (like 1  
>> label one
>> textbox) cdxml and show how to bind controls in it to some other  
>> object.
> 
>       Give the control a RegID, and then bind to 'self.Form.theRegID'.  
> Dabo Referencing 101.

Um, I totally don't get it.


"Give the control a RegID" - I am guessing you mean set something like 
RegID="host" in the cdxml:

  <dTextBox sizerInfo="{'BorderSides': ['All'], 'Proportion': 1, 'HAlign': 
'Left', 'VAlign': 'Top', 'Border': 0, 'Expand': True}" Name="dTextBox2" 
Height="32" Width="245" designerClass="controlMix" DataField="Host" 
RegID="host" 
DataSource="uLoopBO1"></dTextBox>

"bind to 'self.Form.theRegID'" - so self.Form.host - I have no idea what/where 
to do with that.

> 
>>    def _getHost(self):
>>      return self.Host
>>
>>    def _setHost(self, val):
>>      self.Host=val
>>
>>    Host = property(_getHost, _setHost, None,
>>      _("""Hostname of sql database server"""))
> 
> 
>       This won't work!

yeah, noticed that when I was doing some testing.  whooops.

Is this better:


class uLoopBO(dabo.biz.dBizobj):

   def _getHost(self):
     return self._host

   def _setHost(self, val):
     self._host=val

   Host = property(_getHost, _setHost, None,
     _("""Hostname of sql database server"""))

   def initProperties(self):
     self.Host = 'localhost'

app = dabo.dApp()
uLoopBO1 = uLoopBO(None)
app.MainFormClass = 'uloop.cdxml'
app.start()

I am guessing I need to store uLoopBO1 somewhere.

Carl K


_______________________________________________
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/dabo-users/[EMAIL PROTECTED]

Reply via email to