如何写"(双引号)到文件. [英] How to write " ( double quotes) to a file.

查看:162
本文介绍了如何写"(双引号)到文件.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好,
请帮助我解决这个问题
现在,我需要在输出文件上加上()双引号.
但我不能定义它或将其分配给任何变量.请帮忙.

Hello ,
Please help me with this problem
Now i need to write (") double quotes on to the output file.
But i cant define it or assign it to any variable. Please help.

推荐答案

string s = @"""";
or
string s = "\"";


您不能简单地加倍吗?例如:

@"""




"\"帮助"\"


请注意,您尚未说明输出文件的格式或数据来自何处,以及我猜的是哪种格式.
Couldn''t you simply double up? Something like:

@"""help"""


or

"\"help"\"


Note that you have not stated what the format of the output file or where the data is coming from and in what format that is so I''m guessing.


您可以使用
You may use
strLine = CHR(34) & "Test Data" & CHR(34) 




or

strLine = """ & "Test Data" & """


这篇关于如何写"(双引号)到文件.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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