1.创建

wxCheckBox* m_chbMer = new wxCheckBox( this, wxID_ANY, _( "MER:" ), wxDefaultPosition, wxDefaultSize, 0 );
    fgSizer->Add( m_chbMer, 0, wxALIGN_CENTER_VERTICAL | wxLEFT | wxRIGHT, 8 );

2.判读是否选中

wxString::Format( "%d", m_chbMer->IsChecked() )

bool IsChecked();

3.设置复选框的值

 m_chbMer->SetValue( checked );

4.头文件

#include <wx/checkbox.h>
07-20 01:18