How to convert NSIndexpath into NSInteger or simply int?

后端 未结 6 1028
轻奢々
轻奢々 2021-01-30 20:34

I need to convert a nsindexpath var into NsInteger or simply an int. e.g:

 int rowIndex = [mGoogleBaseTable selectedRow];
 //mGoogleBaseTable is a NSTable type          


        
6条回答
  •  醉话见心
    2021-01-30 21:10

    Simply convert into int by,

    NSIndexPath *path = ... // some indexpath

    int row = (int)path.row;

提交回复
热议问题