在xp下编译后,在win7中运行,可以设置但连接时总提示密码不对。
之前用delphi7在win7下编译运行通过,并用手机的wifi连接上了。怎么回事啊。
之前用delphi7在win7下编译运行通过,并用手机的wifi连接上了。怎么回事啊。
解决方案 »
- D7中如何传递需要的值给ASP的session
- form1.create 和form1.activate的区别
- 血一口就喷了出来,关于FASTREPORT的主从表BAND的问题
- 初学者的问题,在线等
- DELPHI中有没有类似VB中SUBST()字符截取的函数啊 (不懂就问,理所当然)
- 急!!!!我的课程设计题目----《校历表的制作》 在线等
- 50分怎样将自己的程序安装完后,加入到系统控制面板添加与删除程序列表中,不用第三方安装程序制作工具。
- [求助]关于类中的Integer型问题
- Delphi 程序使用 XP 风格后的大 BUG!!!!
- 寻找扫描(免费)控件 急 求援
- 求东进D161A模拟卡简单的外拨程序
- 关于form.Brush.Style := bsClear 刷新的问题。急!
//AName:无线AP名称,不超过32个字符
//APass:密码,至少8个字符
//function SetSoftAP(AName, APass: string): Boolean;
//var
// phClient: THandle;
// dwVer, dwRet: DWORD;
// pwhnr: WLAN_HOSTED_NETWORK_REASON;
// pwhnc: WLAN_HOSTED_NETWORK_CONNECTION_SETTINGS;
// pTemp: PAnsiChar;
// pb: BOOL;
//begin
// Result := False;
// dwRet := WlanOpenHandle(1, nil, @dwVer, @phClient);
// if dwRet <> ERROR_SUCCESS then
// Exit;
//
// dwRet := WlanHostedNetworkInitSettings(phClient, @pwhnr, nil);
// if dwRet = ERROR_SUCCESS then
// begin
// pTemp := PAnsiChar(AnsiString(AName));
// pwhnc.hostedNetworkSSID.uSSIDLength := lstrlenA(pTemp);
// ZeroMemory(@pwhnc.hostedNetworkSSID.ucSSID, 32);
// CopyMemory(@pwhnc.hostedNetworkSSID.ucSSID, pTemp, lstrlenA(pTemp));
// pwhnc.dwMaxNumberOfPeers := 10;
// //设置无线AP的名称
// dwRet := WlanHostedNetworkSetProperty(phClient,
// wlan_hosted_network_opcode_connection_settings,
// SizeOf(pwhnc), @pwhnc, @pwhnr, nil);
// if dwRet = ERROR_SUCCESS then
// begin
// pb := True;
// //启用网络承载
// dwRet := WlanHostedNetworkSetProperty(phClient,
// wlan_hosted_network_opcode_enable, SizeOf(pb), @pb, @pwhnr, nil);
// Form1.mmo1.Lines.Add(IntToStr(dwRet) + ': 2');
// if dwRet = ERROR_SUCCESS then
// begin
// pTemp := PAnsiChar(AnsiString(APass));
// //设置无线AP的密码
// dwRet := WlanHostedNetworkSetSecondaryKey(phClient, lstrlenA(pTemp) + 1,
// PUCHAR(pTemp), True, False, @pwhnr, nil);
// Form1.mmo1.Lines.Add(IntToStr(dwRet) + ': 3');
// if dwRet = ERROR_SUCCESS then
// begin
// //开启无线AP
// dwRet := WlanHostedNetworkStartUsing(phClient, @pwhnr, nil);
// Result := dwRet = ERROR_SUCCESS;
// end;
// end;
// end;
// end;
// WlanCloseHandle(phClient, nil);
//end;
http://download.csdn.net/detail/lght/3795678
var AName, APass: PWideChar;