回复 3楼avril1991的帖子
您的描述非常清晰,我写了几行代码复原了您的场景:
- this.fpSpread1.Width = 500;
- this.fpSpread1.ActiveSheet.ColumnCount = 5;
- for (int i = 0; i < 4; i++)
- {
- this.fpSpread1.ActiveSheet.Columns[i].Width = 100;
- }
- fpSpread1.ActiveSheet.Columns[4].CellType = new TextCellType() { WordWrap = true};
- this.fpSpread1.ActiveSheet.Columns[4].Width = 200;
- this.fpSpread1.ActiveSheet.Cells[0, 4].Text = @"sadfffffffkjlskdjflksjdflkjskljkjlkjkjlkjlkjlkjlkjlkjlkjkjkjkjkjlkjlkjlkjlkjlkjlkjlkjlkjlkjlkjlkjlkjsadfffffffkjlskdjflksjdflkjskljkjlkjkjlkjlkjlkjlkjlkjlkjkjkjkjkjlkjlkjlkjlkjlkjlkjlkjlkjlkjlkjlkjlkj";
复制代码
添加个TextCellType,设置WordWrap 为true看看效果能用不。 |