Questions tagged as 'winforms'

1
answer

How can I pass a value from a class to a Listbox

I am involved in a small personal project, composed of some classes and many forms. I need to send a value that is obtained when I access the given button, for the listbox that is in one of these forms. For this I chose to build a method called...
asked by 03.03.2014 / 16:21
1
answer

Add a new variable to a component (PictureBox)

I am creating a game for a college job, this game consists of several Picturebox , one is the main character who walks, jumps and shoots, PictureBox of shots and PictureBox of monsters (randomly generated by a Random ),...
asked by 22.11.2018 / 15:00
1
answer

Include a search button inside a cell gridview c #

I have the following problem: I have a gridview on a Windows form system that I'm developing with C #. This grid will serve for the user to include items of a quote. In the product cell, where the user types the product code, I would like a b...
asked by 25.07.2014 / 15:52
1
answer

Mapping controls windows forms

I'm developing a descktop application in C # The 4.5 framework I did not think the application could grow and have many fields, so there was a need to do automatic (from / to) mapping of controls to entities ... Example. public Pessoa Ge...
asked by 09.08.2018 / 12:48
2
answers

How to find a comma inside a TextBox

I have a Text Box in which it can only contain a comma, so I thought about having the program detect when the user uses the comma if there already exists one in that particular Text Box. Here is an example of the code I want to get: if(...
asked by 03.08.2018 / 14:55
3
answers

Program to rename files

I am trying to develop a small program to rename batches of files (pdf, etc). Imagine that the default is "1250_F1_001A_E01-001A00.pdf" and in the end it would get "1250_F1001A00.pdf", it kept the first 7 and the last 6 of any file. What's in th...
asked by 25.07.2018 / 17:35
1
answer

How to migrate a system made in C # using ASP.NET?

Good morning! I am new to the programming environment and am developing a system in C # using Windows Forms. In the future I intend to do this same system in ASP.NET. I would like to know if there is any way to make the most of the code already...
asked by 28.06.2018 / 16:35
1
answer

Scroll bar in wrong position - DataGridView

I'm trying to select the last row in a DataGridView after adding a new item. For this I am executing the following code: dgwVenda.ClearSelection() dgwVenda.Rows(dgwVenda.Rows.Count - 1).Selected = True If dgwVenda.Controls(1).Visible = True Th...
asked by 21.06.2018 / 20:23
1
answer

How to make a button with rounded corners in C # (Winforms)

I'm trying to customize the appearance of a button, basically I'm trying to customize the edges, background, font color and round the corners of the button. I was able to do everything but round the corners of the button . I tried following a...
asked by 11.01.2015 / 01:25
2
answers

Problem with connection variable to Bank C # Visual Studio

I have my connection string that takes the connection variable from the App.Config static String string_conn = ConfigurationManager.ConnectionStrings["bd1"].ConnectionString; But I put a function that lists the banks in a Combobox in the lo...
asked by 31.05.2018 / 20:15