mfc - Set CSliderCtrl to move in 10 unit intervals -


i have csliderctrl , set this:

m_sliderservertimeout.setrange(10, 600); 

i have event handler:

void cothersettingsemailinfopage::onhscroll(uint nsbcode, uint npos, cscrollbar* pscrollbar) {     if (pscrollbar->getdlgctrlid() == idc_slider)     {         updateservertimeoutdescription();     }      cmfcpropertypage::onhscroll(nsbcode, npos, pscrollbar); } 

works fine want slider move in 10 unit intervals.

how?

update

i tried using setlinesize , setpagesize don't apply when slider dragged.

just use slider metric want. use 1/10th in range of values.

m_sliderservertimeout.setrange(1, 60); 

and when want use data, scale set value *10.


Comments

Popular posts from this blog

node.js - Node js - Trying to send POST request, but it is not loading javascript content -

javascript - Replicate keyboard event with html button -

javascript - Web audio api 5.1 surround example not working in firefox -