wxpython 4.01 / Python 3.7中的事件函数的值

问题描述 投票:0回答:1

我尝试为自己的任务制作小型应用我有问题

应用程序结构是这个


import wx

class panel

    def __init__(......)

        combobox
        bind combobox with event

   location A : string = selected combobox string(catch from def comboboxevent)


    def comboboxevent 

        selected combobox string


和这里->如何在位置a处捕获选定的组合框字符串

  1. 从组合框中选择内容
  2. 点击内容
  3. 与组合框绑定事件
  4. 在绑定函数“ def comboboxevent”处可以发送“选定的组合框内容放置?(位置A)] >>
<<

传递给事件处理程序函数的事件参数包括可用于获取所选项目索引的GetSelection方法和用于获取该项目标签的GetString方法。
events combobox wxpython
1个回答
0
投票
© www.soinside.com 2019 - 2024. All rights reserved.