Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to get and set tabindex in jquery

Tags:

jquery

Im going to set tab index,

$("#DilutionFactor1_" + nCount).attr(
       'tabindex',
       $("#UnitOfMeasure" + nCount).attr('tabindex')+ 1) ;

but this is not working. Anyone can help me to solve this?

like image 743
Madura Harshana Avatar asked Dec 27 '22 12:12

Madura Harshana


1 Answers

try to use parseInt

 $("#DilutionFactor1_" + nCount).attr('tabindex',
parseInt($("#UnitOfMeasure" + nCount).attr('tabindex'))+ 1) ;
like image 183
Kanishka Panamaldeniya Avatar answered Dec 29 '22 02:12

Kanishka Panamaldeniya