如何读取.cs文件并将其转换为.txt文件? [英] How to read the .cs file and convert into .txt file?

查看:479
本文介绍了如何读取.cs文件并将其转换为.txt文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好!请告诉我如何读取.cs文件并将其转换为.txt文件?

hi everyone!please tell me how to read the .cs file and convert it into .txt file?

推荐答案

为什么?出于所有实际目的,.cs文件是文本文件.只需重命名文件扩展名就可以了.
why? For all practical purposes, .cs file is a text file. Just rename the file extension and you are in business.


如果您的.cs文件存在于其他根目录或特殊文件夹(如app_code)中,那么您可以像读取文本一样正常阅读使用streamreader.

或另一种最简单的解决方案,只需将.cs文件复制到新位置,然后将扩展名从.cs更改为文本即可,如Yusuf
If your .cs file exist in other then root directory or in special folder like app_code, then you can read normally like reading a text by using streamreader.

or another simplest solution, just copy the .cs file in new location and change the extension from .cs to text as already mentioned by Yusuf


已经阅读过.如何读取.cs文件?"
正常阅读.这是一个文本文件.

如何将其转换为.txt文件?"
没做什么.它已经是一个文本文件了.
"How to read the .cs file?"
Read it normally. It is a text file.

"How to convert it into .txt file?"
Do nothing. It is already a text file.


这篇关于如何读取.cs文件并将其转换为.txt文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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