在EXCEL中移动细胞系 [英] Moving the cell lines in EXCEL

查看:65
本文介绍了在EXCEL中移动细胞系的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在一个单元格中的新行上移动文本.

例如,我有文字:
abcdefg

我想要:
abcd
efg


我尝试过了.

How to move text on new line in one cell.

Example, i have text :
abcdefg

i want :
abcd
efg


I tryed this.

Range = mySheet.get_Range("C3", "C3");
range.Value2 = string.Concat(cell_value,"\n","/n")



不起作用

不好意思的英语



not working

Excuse for bad English

推荐答案

如果只想换长文本,请设置wrap属性:
If you just want long text to wrap, set the wrap property:
range.WrapText = True;



如果您确实有要强制分隔单元格行的内容,请尝试插入Char(10):



If you actually have content that you want to force to separate lines of the cell, try inserting a Char(10):

range.Value2 = cell_value1 + (Char)10 + cell_value2;


这篇关于在EXCEL中移动细胞系的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆