Most voted "winforms" questions
Winforms is the informal term given to Windows Forms, is a graphical interface application included as part of Microsoft . NET Framework. Winforms provides native visual access to Microsoft Windows window interface using existing Windows API in managed code.
Learn more…1,192 questions
Sort by count of
-
0
votes1
answer28
viewsVisualstudio Designer does not generate some variables
In the Visualstudio 2010 I am having this problem, where some components have no variables and they are initialized in the method InitializeComponent. But in this way the components are not…
-
0
votes2
answers161
viewsHow Forms are opened - Visual Studio
Good morning, My problem is that when I start the program it gets like this: That is, the form child nor scroll bar has there cut the other options To solve, I maximize the parent form, but it looks…
-
0
votes1
answer159
viewsVirtual method with Generic C#
I am creating a Base Form where I am not using it of type "Generic" due to problem with inheritance of forms in C# with the same. In this base form, I had the need to create a virtual method with…
-
0
votes2
answers207
viewsUse different screen resolution according to the monitor
I am developing an application in 1920x1080, but the Pcs that will run are 1280x720 and 1366 x 768. When I run in mine it looks exactly as I want, but when I run in these resolutions, a lot is…
-
0
votes2
answers55
viewsUse Relative Form in Usercontrol
I’m trying to create a Usercontrol so you can call different Forms, however changing only the controls he make the call. Shows the error that the "Form" is non-existent. public partial class…
-
0
votes1
answer70
viewsIs it possible to create a class from a Forms opening routine? How?
I have several forms that I’m 'instantiating' by the event click on the toolstrip, but it seems that it is getting polluted since all codes do the same routine changing only the parameters. Event to…
-
0
votes1
answer325
viewsInsert date written to the textbox in a certain format for the database
Code: private void button1_Click(object sender, EventArgs e) { conn.Open(); using (SqlCommand cmd = new SqlCommand("INSERT INTO (StartDate) VALUES(@StartDate)", conn)) {…
-
0
votes1
answer598
viewsMVC architecture - Windows Forms
How to implement the MVC standard using Windows Forms? I would like to understand better how to separate the Views, Controllers and Models following this development model.
-
0
votes1
answer122
viewsError trying to save information to the database via Entity Framework
My project has the following classes: public class Manifestacao { public long Id { get; set; } public string NumeroChamado { get; set; } public virtual Cliente Cliente { get; set; } public virtual…
-
0
votes1
answer213
viewsBlank tablix
I tried using Report Viewer, but the data from Tablix is blank Load from the form: reportViewer1.LocalReport.DataSources.Add(new Microsoft.Reporting.WinForms.ReportDataSource("Tablix1",…
-
0
votes1
answer63
viewsPicking up content from a textbox from another frame
Guys I need a little help, I have an app that I need to pick up the contents of a textbox in another form to put in a homebody. private void PDVForm_Load(object sender, EventArgs e) { var Operador =…
-
0
votes1
answer239
viewsCheck checked item
I have the following code inside the Itemchecked event: private void lsvRecebeGrupoLayout_ItemChecked(object sender, ItemCheckedEventArgs e) { Layout lay = new Layout(); GrupoLayout grupo = new…
-
0
votes1
answer168
viewsCreate a list with a Model and an Int in C#
I have the following class: using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Dynamic; namespace Model { class PromocaoQtdeVendidaModel { private int…
-
0
votes1
answer41
viewsRescue button through id
Good night, I’m developing a graph, academic work.. .. The idea is to make a "maze", so I go the same at runtime, and I keep a "reference" of each button in a list, but I got to a point where I need…
-
0
votes1
answer83
viewsHow can I use CSS styles in windows Forms c#
I have a lot of difficulties in doing the graphical part of the programs, someone who can help me with some simple example, it doesn’t have to be very complex, because this is a final course work.…
-
0
votes1
answer236
viewsWhat is the difference between Text Box and Input?
I’m making a medium fidelity prototype in the Pencil app and would like to know the difference between a Text Box field and Input and when to use them: Thank you!…
-
0
votes1
answer82
viewsHow to print a flumulario containing tables (grid) via c#
I need to generate a crediario card impression similar to the one that is attached. I have no idea how to do this, what tool to use. Could someone give me a hint? Thank you very much.…
-
0
votes0
answers23
viewsIconbutton Fontawesome.Sharp Error
I’m using an extension, Fontawesome.Sharp in my Winforms project. I never had problems using Iconbutton with font icons but in this project, when I run, sometimes the icons I set in the button…
-
0
votes0
answers53
viewsSend text to a textbox using another Winform C#
I am developing a system, and in this system I need to pass the client name to a text box that is in another form, that is to say I needed the TxtCliente was public, so that then I could go in the…
-
0
votes2
answers64
viewsCellclick event, does not return Datetime value
I’m recording some data on DataGridView and in the Event CellClick should fill in the DateTimePicker with the value already registered, but I’m doing something wrong. Buttons: record, edit, delete…
-
0
votes0
answers18
viewsHow to start a windows form application with operating system?
Hello, how do I get my windows form application to launch along with windows?
-
0
votes1
answer51
viewsMaskedtextbox how to put mask dynamically in Windows Forms C#
How do I hide the mask and only show it as the user fills the field (dynamically)? E.g.: In a xx/xx/xxxx date the bar appears only when it arrived at it. In the events of the component I only found…
-
0
votes1
answer292
viewsCalculate circular Progressbar time C# (Windows Forms)
I have the following circular Progressbar, the idea is that it be decremented second by second, so far so good. However, I need the bar to always start complete (circling the circle 100%) and the…
-
0
votes1
answer117
viewsAdding lines from an array to a Window Form list view
I am doing a project to solve the binomial of Newton, this part is easy I managed to solve the problem on the console the way I wanted, now I am migrating to Windows Form and I have a problem to…
-
0
votes2
answers42
viewscombobox C#, Selectedtext vs Selecteditem.Tostring()
What’s the difference between the two? Can values be different if an error occurs because of this? Which takes up more memory? Apparently the two return the same value, but I would like to remove…
-
0
votes1
answer42
viewsPass values from a Usercontrol to the parent Form
I own a Form main and 4 UserControl with some TextBox, those UserControl is inside this Form and my intention is to take the values of the fields of these UserControl from a button on Form main, for…
-
0
votes0
answers27
viewssum the values of the repeated names in Datagridview
Hello, folks all right, I have an application where I add the items in Datagridview, however I want to add the volume values, the lines that are with the same name, I want to create a variable to…
c# sql-server entity-framework winforms visual-studioasked 3 years, 4 months ago Mecleudio Queiroz 31 -
0
votes0
answers36
viewsWhy is the Activated event triggered more than once?
I need an event, which is triggered every time the user clicks Form, tried to use the event Activated but the event is shot 8 times for the same click. I’d like to understand why it’s shot so many…
-
0
votes1
answer967
viewsSystem.Argumentexception: 'Invalid parameter. '
I created a button with button24_Click_1 to take printscreen from Form1: private void button24_Click_1(object sender, EventArgs e) { var frm = new Form1(); using (var bmp = new Bitmap(frm.Width,…
-
0
votes1
answer82
viewsHow to check if the line was broken?
I use File.ReadAllText to read the text inside a file .txt. private void label9_TextChanged(object sender, EventArgs e) { string text = File.ReadAllText($@"{pathname}", Encoding.UTF8); if…
-
0
votes1
answer281
viewsError using System.Windows.Forms.SendKeys.Send("%{DOWN}")
In a windows form application I have a Datetimepicker and I do not want it to display the date so I did the following: public CadNovoPagamento() { InitializeComponent(); dtpEmissao.Value =…
-
0
votes1
answer162
viewsHow to use Drawtobitmap in WPF to take screen print?
Follows functional code of the WinForms: Bitmap pic = new Bitmap(label1.Width, label1.Height); Rectangle rect = new Rectangle(0, 0, label1.Width, label1.Height); rect = label1.ClientRectangle;…
-
0
votes1
answer43
viewsProperties Linklabel Windownsforms
You can use the property LinkLabel to open a kind of Modal to view history of a particular item that are stored in table ? Example: And in that Form would bring that info that is stocked from the…
-
0
votes1
answer2137
viewsThe method or operation is not implemented c#
I cannot identify the reason for this mistake, since I made other developments with this logic and it worked. The method or operation is not implemented. Follows code: Method that starts the values:…
-
0
votes1
answer753
viewsView PDF document windows Forms
Is there any property of viewing a file . PDF from the event Click on Picturebox without having to create a new modal? Example: I have this Picturebox, where I created the code below, as soon as it…
-
0
votes2
answers743
viewsMicrosoft Visual Studio 2013 - There were compilation errors. Do you want to continue and run the last successful compilation?
Guys, here’s the deal: I’m developing a program Windows Form for desktop in the C# using the Visual Studio 2013. However, sometimes when I click on iniciar/ start some project compilation errors…
-
0
votes2
answers230
viewsListview with first column exceeding limit
Hello! I made a form using the library Materialskin In this library there is a component called Listview (which would be similar to Winforms' Listview) that the first column gets bugged. Look at…
-
0
votes0
answers81
viewsWrite to a listbox in another form
Good stack. I am developing a small application for automatic backup of Mysql and SQL Server databases. The application is to be made in Windows Forms + C#. I thought to implement something similar…
-
0
votes2
answers284
viewsVS 2015 SOAP does not work, but in Soapui works normal
In the company there is a Service available through Webservice SOAP (IBM BPM). I can’t get an answer on VS 2015 using the Web Reference a connection with this service. I always get the answer after…
-
0
votes3
answers161
viewsManipulation of Textbox
You simply fill in the fields Modelo, Placa, Km and it will be saved in the fields multiline down below: But when I click on the "Save" button the result is totally opposite to the expected one. I…
-
0
votes2
answers146
viewsHow to associate items from a String list to the code name of a C#label?
My goal is to play a hangman’s game. Basically my problem is this: I have a word divided into substrings for each letter of the word, all stored in an array. For example: string[] letras = new…
-
0
votes1
answer32
viewsProblem when changing backgronud color of expressions of a richTextBox
I made a code to change the backcolor of all richTextBox expressions starting with a @. It’s all ok, however, there is an error that I’m not able to solve. If the first thing I write is @expression…
-
0
votes1
answer372
viewsClass to write/read formatted TXT files
I’m using the Classe Textwriter to read/write a card receipt on .txt however it does not have the property of formatting letter size, spacing, etc. This makes the proof printed on the thermal…
-
0
votes1
answer41
viewsSubmitchanges() does not update data in Linq
internal bool AlterarCargo(string login, string Categoria) { db.Log = Console.Out; //tentei ativar para ver se encontrava o erro mas não ajudou nada. var categoria = from x in db.Categorias where…
-
0
votes1
answer138
viewsHow to create Checkbox dynamically with windows Forms?
I have a list that returns from the database and for each record I need to create a checkbox of dynamic form, I did a search and found some examples for Webforms and I need an example for Windows…
-
0
votes1
answer44
viewsError while backing up wpf c#
I am having trouble performing backup on my system. I’m using WPF with SQLSERVER 2008, on that system I need to backup the data on the client’s local machine, then I’m creating the backup directory…
-
0
votes2
answers329
viewsWhat’s wrong with my code?
I want to make a program that checks if any file is null but this casting an exception, which is wrong in my code?: static List<string> GetFiles(string path) { string[] directories =…
-
0
votes0
answers390
viewsVS2017 locking in design mode
Good afternoon to all. For a few days now I have been facing a problem in VS2017 that is irritating me a bit!! I have a form with a usercontrol developed by me and some grids. One of these grids was…
-
0
votes0
answers39
viewsThe value change in the integer array in one index works in one case, and in another it doesn’t, why?
private void btnRodaLabirinto_Click(object sender, EventArgs e) { char[,] Lab = new char[10, 10]; int[,] Lab2 = new int[10, 10]; int I = 0, J = 0; Random NumerosRandomicos = new Random(); //abaixo,…
-
0
votes2
answers796
viewsError inserting a "SELECT" item into the Combobox
How do I add an item to the Combobox? The item has to be the first on the list with the text "SELECT": I’m doing like this: private void PreencherCmbIndicacao() { try {…