Items collection cannot be modified when the DataSource property is set Error...
I have two windows formerror show when i need to pass data from windows form2 in textboxto windows form1 comboboxFirst windows Formfound combobox inside windows form1 and I show data in it in load...
View ArticleHow filter values between two textbox values from sql database
Dear sir,I have datalist. in it have some datas. and i have a dropdownlist1 and two textboxes when user type in first textbox1 1000 and second textbox2 10000 while appear between 1000 to 10000 datas in...
View ArticleChange Connection String at runtime
I am developing a Windows Forms VB Project that will allow users to connect to a remote SQL Server database to enter and edit data. During development I have been using the integrated connection string...
View ArticleRead massively XML files and group values in a DataGridView
How to read xml files contained in a folder and group the labels as columns in a DataGridView and the values of the labels as row of the column. Thanks
View ArticleNeed prompt to save changes in Windows form when changing displayed record
I am relatively new to programming, so this may be an easy one. I have a Windows form that connects to SQL Server and displays the data in a form where a user can edit and add or delete records. The...
View ArticleDataGridViewComboBoxColumn Problem - Showing Value Member instead of Display...
Hello, I'm trying to have a combobox column in my datagrid that contains file types records from a datatable (dtFileTypes). I've provided the column with the DataPropertyName, DataSource,...
View ArticleWhen Display data in datagridview it take too much time although data not...
ProblemWhen Display data in datagridview it take too much time although data not more why and how to reduce time .Data Display in datagridview windows form is 325 members only and not big data .It take...
View ArticleHow to get datagridview column's absolute width after using FillWeight?
I want the width of a DataGridView column after using FillWeight. Here is my code (C#, VS2015). I am trying to set textBox widths the same as dgv column widths. The last line of the code is my concern:...
View ArticleHow I can refresh my dataGridView from another form?
Hi Guys first of all I have two Forms first = Form1 and second= Form2 and my dataGridView is on Form1 and my Registration is on Form2 .... When I register something on Form2 then I close my Form2...
View ArticleHow to modify this function to accept Stored Procedure
ProblemI need to modify this function to accept stored procedure in place of tsql statmentDetailsI using function execute data table this function working only by passing tsql statement from c# I need...
View ArticleWrong Reportviewer in toolbox
I need reportviewer control 14 in my toolbox in Visual studio 15.7.4. I have uninstalled and reinstalled report viewer 14.What am I doing wrong?
View ArticleDataGridView Autosize Row/Column
Is there a way to programatically replicate what happens when you double click on the seperator bar of a row/column header to resize it to fit the contents of the column/row? I have multi line rows and...
View ArticleHow to remove all rows in a DataGridView
I have a DataGridView that takes data from a textbox that user inputs. Then, a button that lets user save all rows to database. After saving, I want to remove all rows in the DataGridView. However, the...
View ArticleHow can I update datagridview based on duplicate key?
Hello,I have a method which inserts info into a table(Attendance) that is connected to a datagridview(dg).My question would be how can i determine a duplicate key so that I can update the datagridview...
View ArticleHow to bind values from DatagridView to Item list in C#?
I am doing a Knapsack application in C#. I have an excel file where I have a list of products, price, quantity and from which I populate my datagridview1. When it is populated, I have a TextBox where...
View ArticleCopying DatagridView1 value to Datagridview2 and Add
HI In my project I want to transfer the data of Gridview1 to Gridview2 and add themin a form i want that when i click the button, datagridview1 value to be add in datagridview2 some one please guide me
View Articlewhen writing value in first cell of datagridview win form it give error index...
ProblemI have datagridview have cell 0 is MembershipNo when write any value on datagridview give me error index was out of range Must be non-negative and less than the size of the collection why and...
View ArticleAdd record through bindingsource WITHOUT datagridview.
OK, I have a master/detail form, and when a user clicks create I want to add a record to the form.I am removing the old code that used to create a record in the database using SQL, and then "Fill" the...
View ArticleCopy paste between 2 different DataGridViews
I have created a program to import in a CSV file and display to datagridview. Then I created another datagridview to display on output of a search. Both these work VERY will. However, I want to be able...
View Article