my code has this structure

class Mapsframe(wx.Frame):

    def __init__(self):
        import application


class Example(wx.Frame,listmix.ColumnSorterMixin):
    def __init__(self, *args, **kwargs):
        super(Example, self).__init__(*args, **kwargs) 
        self.InitUI()

    def InitUI(self):

    def onItemSelected(self,event):


            frame = Mapsframe()

and i need to pass two variables which have been created localy inside the def onItemSelected to another python script called application.py any ideas?

Import should be mostly at beginning, so

import application    

class Mapsframe(wx.Frame):
    def __init__(self):
        pass

class Example(wx.Frame,listmix.ColumnSorterMixin):
    def __init__(self, *args, **kwargs):
        super(Example, self).__init__(*args, **kwargs) 
        self.InitUI()

    def InitUI(self):
        pass

    def onItemSelected(self,event):
            frame = Mapsframe()
            application.one_function(frame) #e.g.
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.