如何为表单创建快捷方式

编程入门 行业动态 更新时间:2024-10-11 17:24:20
本文介绍了如何为表单创建快捷方式的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

大家好 在我的项目中,我想为表单创建快捷方式。 就像我有一个链接说创建快捷方式 ,一旦用户点击它,它就应该在面板或列表框中创建特定表单的快捷方式。 然后如果用户关闭应用程序并稍后再打开它们应该在这个地方提供快捷方式。 请告诉我该怎么做。如果我的解释令人困惑,请告诉我.. 谢谢......

解决方案

这个是一种通过它的字符串名称打开表单的方法。

Dim appName As String = Application.ProductName& 。 Dim mForm 作为 字符串 = Form1 Dim f As Form = DirectCast (Type。 GetType (appName& mForm).InvokeMember(mForm,Reflection.BindingFlags.CreateInstance, Nothing , Nothing , Nothing ),表格) f.Show()

这可以帮到你: msdn.microsoft/en-us/library/25zf0ze8(v=vs.80).aspx [ ^ ]

Hi all In my project i want to create shortcut for forms. like i have one link saying "create shortcut", so as soon as the user clicks that,then it should create particular form''s shortcut at a panel or list box. and after that if the user closed the application and opens it again later those shortcuts should be available at the place. Please tell me how to do that. and please tell me if my explanation is confusing.. Thank you...

解决方案

This is a way to open a form by it''s string name.

Dim appName As String = Application.ProductName & "." Dim mForm As String = "Form1" Dim f As Form = DirectCast(Type.GetType(appName & mForm).InvokeMember(mForm, Reflection.BindingFlags.CreateInstance, Nothing, Nothing, Nothing), Form) f.Show()

This could help you: msdn.microsoft/en-us/library/25zf0ze8(v=vs.80).aspx[^]

更多推荐

如何为表单创建快捷方式

本文发布于:2023-11-07 02:12:00,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1565276.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:表单   快捷方式   何为

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!