windows CE下一些目录的变量

作者:dreamzqw

转自:http://blog.csdn.net/dreamzqw/article/details/1749408


When creating an application package, the application developer can use shortcuts to specify the target locations where files should be extracted to on the device. This facilitates localization, because directories can have different names depending on the language that the target device is localized into.

For example, the Windows CE string %CE2% is translated into the Windows directory, typically /Windows on the default storage volume. This translation occurs on the device at installation time.

If a default storage volume is present on the device, the default storage volume string is added to the beginning of the listed directory. For example, if the default storage volume is Storage, %CE1% is automatically changed to /Storage/Program Files when a CE directory identifier is used. The %CEx% string ensures that files are placed in the correct locations on all platforms regardless of the file system's layout.

Note   Windows CE Strings must use uppercase characters.

The following table shows the available Windows CE Strings and their corresponding directory for a target device intended for an English-speaking audience.

Windows CE StringDirectory
%CE1%Program Files
%CE2%Windows
%CE4%Windows/StartUp
%CE5%My Documents
%CE8%Program Files/Games
%CE11%Windows/Start Menu/Programs
%CE14%Windows/Start Menu/Programs/Games
%CE15%Windows/Fonts
%CE17%Windows/Start Menu
 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
Windows CE 是微软公司专为嵌入式系统开发的一款操作系统,它主要用于低功耗设备和嵌入式系统。在Windows CE平台上,可以使用C#或C++编写程序来读取txt文件。 如果是使用C#编写程序,可以使用StreamReader类来读取txt文件。首先,需要在代码中添加命名空间using System.IO,然后可以使用StreamReader的构造方法来创建StreamReader对象,并指定要读取的txt文件的路径: StreamReader reader = new StreamReader(@"C:\example.txt"); 接下来,可以使用ReadLine()方法来逐行读取txt文件的内容。通过读取的每一行,可以根据需要进行处理或保存到其他数据结构中,直到读取到文件的末尾为止。最后,需要使用Close()方法关闭StreamReader对象,释放资源。 示例代码如下: string line; while((line = reader.ReadLine()) != null) { //处理或保存每一行的内容 //... } reader.Close(); 如果是使用C++编写程序,可以使用fstream库来读取txt文件。首先,需要包含头文件#include <fstream>,然后可以创建fstream对象,并调用open()方法并指定要读取的txt文件的路径: std::ifstream file("C:\\example.txt"); 接下来,可以使用getline()方法来逐行读取txt文件的内容,并保存到一个字符串变量中。通过读取的每一行,可以根据需要进行处理或保存到其他数据结构中,直到读取到文件的末尾为止。最后,需要使用close()方法关闭文件流,释放资源。 示例代码如下: std::string line; while(std::getline(file, line)) { //处理或保存每一行的内容 //... } file.close() 以上是在Windows CE平台上使用C#和C++编程语言读取txt文件的基本步骤。具体的实现方式可以根据实际需求进行灵活调整。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值