实现注册表网页超链接调用应用程序实现
发一下牢骚和主题无关:
参考博客:http://www.cnblogs.com/glorysword/archive/2012/08/07/2626008.html
基于BCB的程序计划实现
1.BCB程序实现关键代码
// 页写入网页调用
	TRegistry *Registry1 = new TRegistry;
	Registry1->RootKey = HKEY_CLASSES_ROOT;
	UnicodeString path = "\\Test";
	if(Registry1->OpenKey(path, true)==false)
		ShowMsg(this,"读取注册表失败,没有读取注册表权限,请联系系统管理员!");
	IsNeedDeleteOldVerSoftwareInfo = false;
	if (Registry1->ReadString("") != "URL:Test Protocol") {
		Registry1->WriteString("", "URL:Test Protocol");
		IsNeedDeleteOldVerSoftwareInfo = true;
	}
	if (IsNeedDeleteOldVerSoftwareInfo)
		Registry1->WriteString("URL Protocol", "");
	Registry1->OpenKey(path + "\\DefaultIcon", true);
	strAppPath = Registry1->ReadString("");
	if (strAppPath != ("\"" + Application->ExeName + "\""))
		Registry1->WriteString("", "\"" + Application->ExeName + "\"");
	path += "\\shell\\open\\command";
	Registry1->OpenKey(path, true);
	strAppPath = Registry1->ReadString("");
	UnicodeString ExePath = "\"" + Application->ExeName + "\" " + "%1";
	if (strAppPath != ExePath)
		Registry1->WriteString("", ExePath);
	strAppPath = Registry1->ReadString("OldDefault");
	if (strAppPath != ExePath)
		Registry1->WriteString("OldDefault", ExePath);
	delete Registry1;
	/////////结束
    
 2.网页(html)的计划实现
<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title></title> </head> <body> <a href="Test://aaaaaaaaa/">即时通讯</a> </body> </html>
    
  
文章结束给大家分享下程序员的一些笑话语录: 
3G普不普及现在已经不是看终端了,而是看应用,有好的,便宜实用的应用,花1000多买个能用的智能手机应该不是什么难事。反过来说,你200元拿一个智能手机,没有好的应用,看个电影要几十元,也是没人用3G。
 
                    
                
 
                
            
         浙公网安备 33010602011771号
浙公网安备 33010602011771号