1.在代码中获取对话框中某Control的指针
    如一Dialog中有一ListBox,该ListBox的ID名为“IDC_LBDept”,那么,怎么获取指向它对象的指针呢?如下:
    
    CListBox* pLB    =    (CListBox*)GetDlgItem(IDC_LBDept);
    
    这样,就可以对该ListBox对象进行操作了。
    pLB->InsertString(-1,"Documentation");
    pLB->InsertString(-1,"Accounting");

相关文章:

  • 2021-12-12
  • 2021-05-28
  • 2021-09-15
  • 2021-12-02
  • 2022-12-23
  • 2021-09-02
  • 2021-09-07
猜你喜欢
  • 2021-04-23
  • 2021-04-16
  • 2021-09-22
  • 2021-06-22
  • 2021-05-24
  • 2022-02-19
  • 2021-10-20
相关资源
相似解决方案