将“添加到文本文件”
大家好你能帮帮我吗?
我想把符号写在文本文件中
我尝试了下面的代码,但它无法将此sing添加到文本文件中
怎么了?
下面是我需要添加到文本文件的文本文件
下面是我的代码
(setq f(打开(strcat“c:\\LLMS CAD\\filename.txt”)“a”)
(setq txt1“”)
(写入行txt1 f)
(关闭f)
(普林斯)
)
以下是文件中的文本
在任何论点中使用“for write”。看我的例子。。。用同样的方法写论点
例如
(princ "\" Hello \"")
-> " Hello "
您的代码
(setq txt1
(strcat
"<?xml version=\"\"1.0\"\" encoding=\"\"UTF-8\"\"?><kml xmlns=\"\"http://www.opengis.net/kml/2.2\"\" xmlns:gx=\"\"http://www.google.com/kml/ext/2.2\"\" xmlns:kml=\"\"http://www.opengis.net/kml/2.2\"\" xmlns:atom=\"\"http://www.w3.org/2005/Atom\"\"><Document><name>"
)
) 在下面进行测试
(alert "and then I said, \"test this below\"") 非常感谢satishrajdev和Dan中尉的腿 下面是有关转义字符的更多信息。 非常感谢李·麦克 不客气!
页:
[1]