得到Revit子窗体
start
url:http://greatverve.cnblogs.com/p/get-revit-child-form.html
/// <summary>
/// 得到主窗体句柄
/// </summary>
/// <returns></returns>
public static IntPtr GetIntPtr()
{
return Process.GetCurrentProcess().MainWindowHandle;
}
/// <summary>
/// 得到Revit主窗体
/// </summary>
/// <returns></returns>
public static System.Windows.Forms.Form GetRevitForm()
{
return (System.Windows.Forms.Form)System.Windows.Forms.Control.FromHandle(GetIntPtr());
}
/// 得到主窗体句柄
/// </summary>
/// <returns></returns>
public static IntPtr GetIntPtr()
{
return Process.GetCurrentProcess().MainWindowHandle;
}
/// <summary>
/// 得到Revit主窗体
/// </summary>
/// <returns></returns>
public static System.Windows.Forms.Form GetRevitForm()
{
return (System.Windows.Forms.Form)System.Windows.Forms.Control.FromHandle(GetIntPtr());
}
我这个博客废弃不用了,今天想寻找外链的时候,突然想到这个博客权重很高。
有需要免费外链的,留言即可,我准备把这个博客变成免费的友情链接站点。