[英]DataGridView not avaiable on Visual Studio 2019 ToolBox
[英]Visual Studio 2019 Community toolbox has no webbrowser control
我有一個 WinForms 應用程序,當我設計一個表單時,工具箱沒有顯示 webbrowser 控件。 框架是.NET 5.0。 我使用的是Visual Studio 2019 Community最新版本v16.8.6,如截圖所示。
誰能幫我?
WebBrowser 控件已過時,難以正確呈現大多數現代網站。 我會推薦使用 WebView2 而不是https://docs.microsoft.com/microsoft-edge/webview2/get-started/winforms
我有 VS 2022 和 .NET 6.0,它也不在工具箱中。 我能夠通過編輯 MyForm.Designer.cs 文件來添加它。 我向文件的 4 個部分添加了代碼。 this.webBrowser1 = new System.Windows.Forms.WebBrowser();
//
// webBrowser1
//
this.webBrowser1.Location = new System.Drawing.Point(1064, 24);
this.webBrowser1.Margin = new System.Windows.Forms.Padding(5, 3, 5, 3);
this.webBrowser1.MinimumSize = new System.Drawing.Size(27, 27);
this.webBrowser1.Name = "webBrowser1";
this.webBrowser1.Size = new System.Drawing.Size(405, 506);
this.webBrowser1.TabIndex = 27;
this.Controls.Add(this.webBrowser1);
私人系統.Windows.Forms.WebBrowser webBrowser1;
超級...適合我
this.webBrowser1 = new System.Windows.Forms.WebBrowser();
//
// webBrowser1
//
this.webBrowser1.Location = new System.Drawing.Point(1064, 24);
this.webBrowser1.Margin = new System.Windows.Forms.Padding(5, 3, 5, 3);
this.webBrowser1.MinimumSize = new System.Drawing.Size(27, 27);
this.webBrowser1.Name = "webBrowser1";
this.webBrowser1.Size = new System.Drawing.Size(405, 506);
this.webBrowser1.TabIndex = 27;
this.Controls.Add(this.webBrowser1);
私人系統.Windows.Forms.WebBrowser webBrowser1;
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.