菜鸟问题:怎样实时获取CSliderCtrl的刻度值?谢谢!!

解决方案 »

  1.   

    CSliderCtrl::GetPos
    int GetPos( ) const;
      

  2.   

    CSliderCtrl::GetTicPos
    int GetTicPos( int nTic ) const;Return ValueThe physical position, in client coordinates, of the specified tick  or  – 1 if nTic does not specify a valid index.ParametersnTicZero-based index identifying a tick .ResCall this function to retrieve the current physical position of a tick  in a slider control
    int GetPos( ) const;Return ValueThe current position.ResCall this function to retrieve the current position of the slider in a slider control
      

  3.   

    上面不是说得很清楚了吗!用GetPos()或CSliderCtrl::GetTicPos( int nTic ) const就能直接得到,不用重载。