{"id":394,"date":"2007-09-07T16:47:35","date_gmt":"2007-09-07T08:47:35","guid":{"rendered":"http:\/\/www.jason695.idv.tw:81\/wordpress\/?p=394"},"modified":"2011-02-20T11:35:44","modified_gmt":"2011-02-20T03:35:44","slug":"vbnet%e5%af%a6%e7%8f%be%e7%aa%97%e9%ab%94%e5%9c%96%e6%a8%99%e6%9c%80%e5%b0%8f%e5%8c%96%e5%88%b0%e7%8b%80%e6%85%8b%e6%ac%84","status":"publish","type":"post","link":"https:\/\/jason695.why3s.tw\/wordpress\/2007\/09\/07\/vbnet%e5%af%a6%e7%8f%be%e7%aa%97%e9%ab%94%e5%9c%96%e6%a8%99%e6%9c%80%e5%b0%8f%e5%8c%96%e5%88%b0%e7%8b%80%e6%85%8b%e6%ac%84\/","title":{"rendered":"VB.NET\u5be6\u73fe\u7a97\u9ad4\u5716\u6a19\u6700\u5c0f\u5316\u5230\u72c0\u614b\u6b04"},"content":{"rendered":"<p>\u4f86\u6e90\uff1ahttp:\/\/big5.chinaz.com:88\/www3.chinaz.com\/Program\/.NET\/0P3133E2007.html<\/p>\n<p>\u672c\u6587\u6240\u4f7f\u7528\u7684\u7de8\u7a0b\u74b0\u5883\u662fMicrosoft Visual Studio 2005\uff0c\u9996\u5148\u6253\u958b Visual Studio\u3002\u5728\u6587\u4ef6 (File) \u83dc\u55ae\u4e0a\uff0c\u55ae\u64ca\u65b0\u5efa\u9805\u76ee (New Project)\u3002 \u5728\u65b0\u5efa\u9805\u76ee (New Project) \u5c0d\u8a71\u6846\u7684\u6a21\u677f (Templates) \u7a97\u683c\u4e2d\uff0c\u55ae\u64ca Windows \u61c9\u7528\u7a0b\u5e8f (Windows Application)\u3002\u55ae\u64ca\u78ba\u5b9a (OK)\u3002<\/p>\n<p>\u60f3\u8981\u5c07\u7a97\u9ad4\u5716\u6a19\u6700\u5c0f\u5316\u6642\u81ea\u52d5\u96b1\u85cf\u5230\u4efb\u52d9\u6b04\uff0c\u6211\u5011\u53ef\u4ee5\u4f7f\u7528\u4e00\u500b\u63a7\u4ef6\uff0c\u9019\u500b\u63a7\u4ef6\u7684\u540d\u5b57\u53eb\u505aNotifyIcon\u63a7\u4ef6\uff0c\u6253\u958b\u5de6\u5074\u7684\u5de5\u5177\u7bb1\u627e\u5230 NotifyIcon\u63a7\u4ef6\u76f4\u63a5\u5c07\u5b83\u62d6\u5230\u7a97\u9ad4\u4e0a\u3002\u628aNotifyIcon\u7684Icon\u5c6c\u6027\u8a2d\u4e00\u4e0b\uff0c\u7576\u7136ICON\u5c6c\u6027\u4f60\u53ef\u4ee5\u8a2d\u7f6e\u4e00\u500b\u597d\u770b\u7684\u5716\u6a19\u3002<\/p>\n<p align=\"center\"> <span class=\"Dgk840\"><\/span><\/p>\n<p>\u5c07\u4e0b\u4f86\u55ae\u64caForm1\u7a97\u9ad4\uff0c\u9032\u5165\u5c6c\u6027\u8a2d\u7f6e\u628aForm\u7684WindowState\u8a2d\u6210Minimized;ShowInTaskbar\u5c6c\u6027\u8a2d\u6210False\u3002\u57162<br \/>\n\u63a5\u4e0b\u4f86\u6211\u5011\u5c31\u8981\u8f38\u5165\u4ee3\u78bc\u4e86 <font color=\"#f5fafe\">Chinaz.com<\/font><\/p>\n<p>\u5728Form\u7684Resize\u4ee3\u78bc\u4e8b\u4ef6\u4e2d\uff0c <span class=\"Dgk840\"><\/span><\/p>\n<p class=\"code\">&nbsp;<\/p>\n<table style=\"border: 1px dotted #cccccc; table-layout: fixed\" align=\"center\" border=\"0\" cellpadding=\"6\" cellspacing=\"0\" width=\"95%\">\n<tr>\n<td bgcolor=\"#fdfddf\"><font color=\"#ff0000\">\u4ee5\u4e0b\u70ba\u5f15\u7528\u7684\u5167\u5bb9\uff1a<\/font><br \/>\nPrivate Sub Form1_Resize(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Resize<br \/>\nIf Me.WindowState = FormWindowState.Minimized Then<br \/>\nMe.Hide()<br \/>\nEnd If<br \/>\nEnd Sub<\/td>\n<\/tr>\n<\/table>\n<p><font color=\"#f5fafe\">\u7ad9\u9577.\u7ad9<\/font>\u4ee3\u78bc\u7684\u610f\u601d\u662f\u8b93\u7a97\u9ad4\u6700\u5c0f\u5316\u7684\u6642\u5019\u5c31\u81ea\u52d5\u96b1\u85cf\u5230\u72c0\u614b\u6b04\u3002<\/p>\n<p>\u9019\u6a23\u904b\u884c\u7684\u6642\u5019\u7a97\u9ad4\u5c31\u6703\u81ea\u52d5\u96b1\u85cf\uff0c\u51fa\u73fe\u5728\u72c0\u614b\u6b04\u4e86\u3002 <span class=\"Dgk840\"><\/span><\/p>\n<p>\u60f3\u96d9\u64ca\u5716\u6a19\u7684\u6642\u5019\u986f\u793a\u7a97\u9ad4\u7684\u8a71\u53ef\u4ee5\u8a2d\u7f6eNotifyIcon\u63a7\u4ef6\u7684DoubleClick\u4ee3\u78bc<\/p>\n<p>\u4ee3\u78bc\u5982\u4e0b\uff1a<\/p>\n<table style=\"border: 1px dotted #cccccc; table-layout: fixed\" align=\"center\" border=\"0\" cellpadding=\"6\" cellspacing=\"0\" width=\"95%\">\n<tr>\n<td bgcolor=\"#fdfddf\"><font color=\"#ff0000\">\u4ee5\u4e0b\u70ba\u5f15\u7528\u7684\u5167\u5bb9\uff1a<\/font><br \/>\nPrivate Sub NotifyIcon1_DoubleClick(ByVal sender As Object, ByVal e As System.EventArgs) Handles NotifyIcon1.DoubleClick<br \/>\nMe.ShowInTaskbar = True<br \/>\nMe.Show()<br \/>\nMe.WindowState = FormWindowState.Normal<br \/>\nEnd Sub<\/td>\n<\/tr>\n<\/table>\n<p>\u5982\u679c\u6211\u5011\u60f3\u5275\u5efa\u53f3\u9375\u83dc\u55ae\u7684\u8a71\uff0c\u6211\u5011\u53ef\u4ee5\u5728\u7a97\u9ad4\u4e0a\u6dfb\u52a0\u4e00\u500bContextMenustrip\u63a7\u4ef6\uff0c\u7528NotifyIcon\u7684ContextMenu\u5c6c \u6027\u9032\u884c\u95dc\u806f\u3002\u5728\u5de5\u5177\u7bb1\u4e2d\u9078\u64c7\u83dc\u55ae\u548c\u5de5\u5177\u6b04\uff0c\u76f4\u63a5\u5c07ContextMenu\u63a7\u4ef6\u62d6\u5230\u7a97\u9ad4\u4e0a\u9032\u5165\u5c6c\u6027\u8a2d\u7f6e\uff0c\u8f38\u5165\u76f8\u61c9\u83dc\u55ae\u95dc\u9375\u5b57(\u81ea\u5df1\u60f3\u8f38\u5165\u7684\u6587\u5b57\u5982\u4e0b\u5716\u7684\u8edf\u4ef6 \u7248\u672c\u7b49)\u3002 <font color=\"#f5fafe\">Chinaz.com<\/font><\/p>\n<p align=\"center\">\n<p align=\"center\">\u3000\u3000\u57163 <span class=\"Dgk840\"><\/span><\/p>\n<p>\u7136\u5f8c\u55ae\u64ca\u7a97\u9ad4\u7684NotifyIcon1\u63a7\u4ef6\uff0c\u8a2d\u7f6e\u5c6c\u6027\uff0c\u5728contextmenustrip\u8655\u9078\u64c7\u525b\u624d\u7de8\u8f2f\u904e\u7684\u53f3\u9375\u83dc\u55aeContextMenustrip1\u9032\u884c\u95dc\u806f\u8acb\u770b\u57164<\/p>\n<p align=\"center\">\n<p>\u7136\u5f8c\u6309F5\u904b\u884c\u7a0b\u5e8f\uff0c\u9ede\u64ca\u7a97\u9ad4\u6700\u5c0f\u5316\u6309\u9215\uff0c\u7a97\u9ad4\u7684\u5716\u6a19\u81ea\u52d5\u96b1\u85cf\u5230\u72c0\u614b\u6b04\u4e86\u3002\u9ede\u64ca\u53f3\u9375\u4f60\u53ef\u4ee5\u770b\u5230\u7cbe\u7f8e\u7684\u53f3\u9375\u83dc\u55ae\u3002 <font color=\"#f5fafe\">Chinaz.com<\/font><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u4f86\u6e90\uff1ahttp:\/\/big5.chinaz.com:88\/www3.chinaz.com\/Program\/.N &hellip; <a href=\"https:\/\/jason695.why3s.tw\/wordpress\/2007\/09\/07\/vbnet%e5%af%a6%e7%8f%be%e7%aa%97%e9%ab%94%e5%9c%96%e6%a8%99%e6%9c%80%e5%b0%8f%e5%8c%96%e5%88%b0%e7%8b%80%e6%85%8b%e6%ac%84\/\" class=\"more-link\">\u95b1\u8b80\u5168\u6587 <span class=\"screen-reader-text\">VB.NET\u5be6\u73fe\u7a97\u9ad4\u5716\u6a19\u6700\u5c0f\u5316\u5230\u72c0\u614b\u6b04<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[2],"tags":[],"class_list":["post-394","post","type-post","status-publish","format-standard","hentry","category-net","no-featured-image"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/jason695.why3s.tw\/wordpress\/wp-json\/wp\/v2\/posts\/394","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/jason695.why3s.tw\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/jason695.why3s.tw\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/jason695.why3s.tw\/wordpress\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/jason695.why3s.tw\/wordpress\/wp-json\/wp\/v2\/comments?post=394"}],"version-history":[{"count":0,"href":"https:\/\/jason695.why3s.tw\/wordpress\/wp-json\/wp\/v2\/posts\/394\/revisions"}],"wp:attachment":[{"href":"https:\/\/jason695.why3s.tw\/wordpress\/wp-json\/wp\/v2\/media?parent=394"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/jason695.why3s.tw\/wordpress\/wp-json\/wp\/v2\/categories?post=394"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/jason695.why3s.tw\/wordpress\/wp-json\/wp\/v2\/tags?post=394"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}