我需要使用WinAPI函数来重启一个windows服务,我对C++中的字符串不熟悉。我的函数接收参数:constCStringA&serviceName:boolMyClassName::RestartServer(constCStringA&serviceName)当我通过OpenService(..)获取SC句柄时,我需要提供类型LPCWSTR:SC_HANDLESHandle=OpenService(hSCManager,LPCWSTRserviceNameAsWideString,SC_MANAGER_ALL_ACCESS);如何将CStringA转换为LPCWSTR?我尝试以