开发者

Limiting the text length in a cell in NSTableView column

I have a NSTableView with 2 columns. I do have code to开发者_C百科 enter text in the cells for each row. Is there a way to limit the number of characters entry in the cell say max upto 10?


You can't tell the cell self to cut the NSString. But you can cut the inputString

cell.textLabel.text = [yourString substringToIndex:10];
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜