No hagas un import solo para ejecutar otro script así no funcionan las cosas.
Supongo que quieres hacer mas o menos esto.
Código Python:
Ver original#coding: cp1252
import wx
class Recibo(wx.MDIChildFrame):
def __init__(self, *args, **kwargs):
wx.MDIChildFrame.__init__(self, *args, **kwargs)
panel = wx.Panel(self, -1)
#Textos_Estaticos...
centrocli = wx.StaticText(panel, -1, "Centro Clinico Los Angeles,CA ", pos = (10,10))
fecha = wx.StaticText(panel, -1, "Fecha: ", pos = (200,10))
recipago = wx.StaticText(panel, -1, "Recibo de Pago", pos = (10,30))
bs = wx.StaticText(panel, -1, "Bs: ", pos = (200,30))
nombre = wx.StaticText(panel, -1, "Nombres: ", pos = (10,50))
ci = wx.StaticText(panel, -1, "Cedula: ", pos = (200,50))
dpto = wx.StaticText(panel, -1, "Departamento: ", pos = (10,70))
conforme = wx.StaticText(panel, -1, "He recibido de Centro Clinico Los Angeles la cantidad de: ", pos = (10,90))
concepto = wx.StaticText(panel, -1, "Concepto: Pago Primera Quincena del mes de: ", pos = (10,110))
asignaciones = wx.StaticText(panel, -1, "Asignaciones", pos = (10,130))
class Login(wx.MDIChildFrame):
def __init__(self, *args, **kwargs):
#Ventana hija de prueba Mdi
wx.MDIChildFrame.__init__(self, *args, **kwargs)
#panel
panel = wx.Panel(self, -1, pos = (0,0))
#textos estaticos
usuario = wx.StaticText(panel, -1, "USUARIO", pos = (100,100))
clave = wx.StaticText(panel, -1, "PASSWORD", pos = (100,140))
#cajs de texto
usuariob = wx.TextCtrl(panel, -1, "", pos = (170,100))
claveb = wx.TextCtrl(panel, -1, "", pos = (170,140), style = wx.PASSWORD)
#botones
self.Boton = wx.Button(panel, -1, "Cerrar", size = (100,100), pos = (200,200))
self.Aceptar = wx.Button(panel, -1, u"Aceptar", size = (100,100), pos = (90,200))
self.Boton.Bind(wx.EVT_BUTTON, self.OnExit)
self.Aceptar.Bind(wx.EVT_BUTTON, self.OnAceptar)
self.Center(True)
def OnExit(self, evt):
self.Close(True)
def OnAceptar(self, evt):
self.recibo = Recibo(self.Parent, -1, "Recibo titulo", size = (500,400))
class MDIFrame(wx.MDIParentFrame):
def __init__(self, parent, id, title):
wx.MDIParentFrame.__init__(self, parent, id, title, size=(1024,768))
self.Ventana = Login(self, -1, "Comprobación de Usuario", size = (400,400), pos = (300,200), style = wx.CAPTION | wx.RESIZE_BORDER |wx.SYSTEM_MENU)
self.Ventana.Show()
app = wx.PySimpleApp(0)
frame = MDIFrame(None, -1, "Prueba de ventana MDI")
frame.Maximize()
frame.Show()
app.MainLoop()