ICANN认证国际域名顶级注册机构
网站建设,域名注册,空间租用,软件销售,广告设计 域名注册,空间租用, 网站建设,东莞网页设计,域名注册,网站推广,网站开发,网页设计 网站推广,,百度推广,新浪推广,雅虎推广,网易推广 标志设计,画册设计,包装设计,VI策划,企业形象顾问 连邦软件加盟店,提供销遥行,管家婆,速达,用友ERP,诺顿等软件报价及销售 建站必读 腾达网络,上网帮助中心, 腾达为东莞等地,提供网站建设,网站推广,广告设计,软件销售等优质服务!
建站必读


 
 
当前位置:首页 -> 建站必读 -> .NET技术
thread pool
Now that we have seen the thread pool classes, let us move to creating the object that will handle our custom project template. This is a simple C# class library project, with a single class that implements the IDTWizard interface.

public class CustomWizard : IDTWizard

{

   public void Execute(object application, int hwndOwner,

                     ref object[] contextParams, ref object[] customParams,

                                             ref EnvDTE.wizardResult retval)



   {

      string lProjName = (string)contextParams[1];

      string lSolnName = (string)contextParams[2];



      if (!Directory.Exists (lSolnName))

         Directory.CreateDirectory (lSolnName);



      _DTE lApp = (_DTE)application;

      _Solution lSoln = lApp.Solution;



      lSoln.Create (lSolnName, lProjName);

      lSoln.AddFromTemplate(mProjPath,lSolnName,lProjName,false);

   }



   // NOTE: change this to the path where you store the downloaded files

   private const string mProjPath =

                  @"C:C#TodayCustomWizardsThreadPoolTemplate.csproj";

}

The code block above is all we need for our custom wizard component. The first thing we do in this method is to retrieve the names of the project and the solution that is input by the user in the New Project dialog box. Once that is done, we check to see if the user input path exists, and if not, we use the System.IO.Directory class to create the specified folders. We then use the Solution object from the Visual Studio .NET object model to create a new solution and project based on our ThreadPool classes. We use the AddFromTemplate method of the Solution class to copy over the project files from the thread pool project.

Readers should change the mProjPath variable to point to the location where they have stored the ThreadPoolTemplate.csproj and ThreadPool.cs files.

The .vsdir file for this project template is shown below. We used the Guidgen tool to generate a unique GUID.

Thread Pooled Application.vsz|0|0|0|Generates a

thread pool class.|{FAE04EC1-301F-11d3-BF4B-00C04F79EFBC}|4553|0|0

The .vsz file is as shown below.

VSWIZARD 7.0

Wizard=CustomWizardNS.CustomWizard

Attached Sample Code

The attached sample code contains the CustomWizard and ThreadPoolTemplate projects, and the support vsdir and vsz files.

Please carry out the following steps to set up this sample:

1.    Copy the ThreadPool.cs and ThreadPoolTemplate.csproj files to C:C#TodayCustomWizards. If you need to copy these to a different path, you will have to change the mProjPath member variable in the CustomWizard class from the CustomWizard project.

2.    Copy the Thread Pooled Application.vsdir and Thread Pooled Application.vsz files to C:Program FilesMicrosoft Visual Studio.NETVC#CSharpProjects. Note that this path will be different if you have installed Visual Studio .NET in a different location. Substitute your install path for C:Program FilesMicrosoft Visual Studio.NET.

3.    Compile the CustomWizard project.

4.    Copy CustomWizard.dll to C:Program FilesMicrosoft Visual Studio.NETCommon7IDE. This is again assuming the de
 
 
本站关键词:
|横沥网站建设网页制作|常平网站建设网页制作|虎门网站建设网页制作|厚街网站建设网页制作|长安网站建设网页制作|石龙网站建设网页制作|东坑网站建设网页制作|东莞专业网络公司|东莞速达软件|东莞财务软件|东莞ERP软件|东莞电脑维护||横沥网站建设网页制作|常平网站建设网页制作|虎门网站建设网页制作|厚街网站建设网页制作|长安网站建设网页制作|石龙网站建设网页制作|东坑网站建设网页制作|东莞专业网络公司|东莞速达软件|东莞财务软件|东莞ERP软件|东莞电脑维护||横沥网站建设网页制作|常平网站建设网页制作|虎门网站建设网页制作|厚街网站建设网页制作|长安网站建设网页制作|石龙网站建设网页制作|东坑网站建设网页制作|东莞专业网络公司|东莞速达软件|东莞财务软件|东莞ERP软件|东莞电脑维护||横沥网站建设网页制作|常平网站建设网页制作|虎门网站建设网页制作|厚街网站建设网页制作|长安网站建设网页制作|石龙网站建设网页制作|东坑网站建设网页制作|东莞专业网络公司|东莞速达软件|东莞财务软件|东莞ERP软件|东莞电脑维护||横沥网站建设网页制作|常平网站建设网页制作|虎门网站建设网页制作|厚街网站建设网页制作|长安网站建设网页制作|石龙网站建设网页制作|东坑网站建设网页制作|东莞专业网络公司|东莞速达软件|东莞财务软件|东莞ERP软件|东莞电脑维护||横沥网站建设网页制作|常平网站建设网页制作|虎门网站建设网页制作|厚街网站建设网页制作|长安网站建设网页制作|石龙网站建设网页制作|东坑网站建设网页制作|东莞专业网络公司|东莞速达软件|东莞财务软件|东莞ERP软件|东莞电脑维护||横沥网站建设网页制作|常平网站建设网页制作|虎门网站建设网页制作|厚街网站建设网页制作|长安网站建设网页制作|石龙网站建设网页制作|东坑网站建设网页制作|东莞专业网络公司|东莞速达软件|东莞财务软件|东莞ERP软件|东莞电脑维护||横沥网站建设网页制作|常平网站建设网页制作|虎门网站建设网页制作|厚街网站建设网页制作|长安网站建设网页制作|石龙网站建设网页制作|东坑网站建设网页制作|东莞专业网络公司|东莞速达软件|东莞财务软件|东莞ERP软件|东莞电脑维护||横沥网站建设网页制作|常平网站建设网页制作|虎门网站建设网页制作|厚街网站建设网页制作|长安网站建设网页制作|石龙网站建设网页制作|东坑网站建设网页制作|东莞专业网络公司|东莞速达软件|东莞财务软件|东莞ERP软件|东莞电脑维护||横沥网站建设网页制作|常平网站建设网页制作|虎门网站建设网页制作|厚街网站建设网页制作|长安网站建设网页制作|石龙网站建设网页制作|东坑网站建设网页制作|东莞专业网络公司|东莞速达软件|东莞财务软件|东莞ERP软件|东莞电脑维护||横沥网站建设网页制作|常平网站建设网页制作|虎门网站建设网页制作|厚街网站建设网页制作|长安网站建设网页制作|石龙网站建设网页制作|东坑网站建设网页制作|东莞专业网络公司|东莞速达软件|东莞财务软件|东莞ERP软件|东莞电脑维护||横沥网站建设网页制作|常平网站建设网页制作|虎门网站建设网页制作|厚街网站建设网页制作|长安网站建设网页制作|石龙网站建设网页制作|东坑网站建设网页制作|东莞专业网络公司|东莞速达软件|东莞财务软件|东莞ERP软件|东莞电脑维护||横沥网站建设网页制作|常平网站建设网页制作|虎门网站建设网页制作|厚街网站建设网页制作|长安网站建设网页制作|石龙网站建设网页制作|东坑网站建设网页制作|东莞专业网络公司|东莞速达软件|东莞财务软件|东莞ERP软件|东莞电脑维护||横沥网站建设网页制作|常平网站建设网页制作|虎门网站建设网页制作|厚街网站建设网页制作|长安网站建设网页制作|石龙网站建设网页制作|东坑网站建设网页制作|东莞专业网络公司|东莞速达软件|东莞财务软件|东莞ERP软件|东莞电脑维护|
域名注册 | 虚拟主机 | 网站建设 | 网站推广 | 广告设计 | 帮助中心 | 软件中心 | 关于腾达
东莞市腾达信息工程有限公司      本站网络实名: 东莞网站建设
地址:东莞市新城市中心区第一国际B座610   邮编:523007
电话:0769-22026071 22026072 传真:0769-22026076 24小时服务热线:13712032014
© 2002~2005 腾达网络   版权所有