12 2022 档案
摘要:设置工程属性中的字符集Character Set为多字节字符集还是Unicode引发两个bug后,找到如下资料: 解决方法一: 通常手动输入的字符串都是const char*(即LPCSTR)类型的,因此只需将该句中的MessageBox改为MessageBoxA即可。 解决方法二: 参数使用“_T
阅读全文
摘要:void main() { //字符串转字符数组 string name = "ddddd"; char buf[] = {0}; strcpy(buf , name.c_str());//字符串转字符数组,使用strcpy cout << name.c_str() << endl;//name.c
阅读全文
摘要:#!/usr/bin/python import xlrd import os ''' #read last line head data with open('ReadMac.txt',"r") as file: file_content = file.readlines() #把全文档读取为一个
阅读全文
摘要:读取文件夹内的所有表,输入想要查询的表名,列出对应表页签,查询对应内容并打印出来 import xlrd print('输入‘x’返回上一步!!!') while True: print('\n输入想要查询的表:') bio_name = input() with open('dizhi.txt',
阅读全文
摘要:#!/usr/bin/python import xlrd # 打开excel表格 data_excel = xlrd.open_workbook('macHex-MMQ873-PCL.xls') # 获取所有sheet名称 names = data_excel.sheet_names() # 获取
阅读全文
摘要:C++ 字符串字母大小写转换 使用algorithm,里面的tolower(转小写)toupper(转大写) #include <iostream>#include <string>using namespace std;#include <algorithm> int main(){ // 字符串
阅读全文