Hi,
It's not the first time I've posted on this list and I've also been checking into dabo now and then. Kudos on your efforts and evolution. It's looking dandy!
I've been checking into sample code, the list and the wiki. And appart from using dabo.ui.createForm(cdxmlFilePath, show=False) and dabo.ui.dForm.addObject(frmclass) methods I can't find any clues on how to actually use cdxml files in code.
Here's what I've been doing (without success ;-(
## import dabo import dabo.db as db import dabo.biz as biz import dabo.ui as ui
class MyConnectInfo(db.dConnectInfo): def initProperties(self): self.DbType = "Firebird" self.Host = "localhost" self.Database = r"C:\fdb\miradouro.fdb" self.User = "sysdba" self.Name = "cx_mira" self.Port = 3050 self.Password = "L2EY35I06K81X35AB6KFDE46O24" # default FB password
ui.loadUI('wx')
class MainForm(ui.dForm): def afterInit(self): frmclass = "frmMain.cdxml" # same directory as App self.addObject(frmclass) # doesn't seem to work MainForm.doDefault() ci = MyConnectInfo() self.Application.addConnectInfo(ci) self.connection = self.Application.getConnectionByName("cx_mira")
def main(): app = dabo.dApp() app.MainFormClass = MainForm app.start()
##
Can you give me some pointers on how to properly use dabo.ui.createForm(frmclass, show=False) and also dabo.ui.dForm.addObject("path/to/.cdxml/file")
What I managed to understand about these methods doesn't seem to be enough for me to make it work.
TIA Miguel
O Clix quebrou mais uma barreira!
ADSL até 20 Mb + Telefone livre de assinatura por apenas € 34,9/mês
Acabe de vez com os € 15 da assinatura telefónica!
Saiba mais em http://acesso.clix.pt
©2006 Miguel Lopes |