1,381 Topics
Hi, I am using Windows Forms (not WPF) to create video controls on the form to view the output from a video stream. What I want to do is based on a list of IP addresses (the addresses being of encoders capturing the video and making it available via a …
I am trying to make a timer that refreshes every 5 seconds. Here is my code: using System; using System.Collections.Generic; using System.Windows.Forms; using System.Diagnostics; using System.Timers; namespace rpanel_server { public partial class MainForm : Form { public MainForm() { InitializeComponent(); Timer MyTimer = new Timer(); MyTimer.Interval = (4000); MyTimer.Tick += …
Hi! i want ADD empty row in DataGridView............Like This ! When user enter Number in textbox and click button then Add empty rows(as per user input number in textbox) in DataGridView.......... for example :- if user entered "5" in textbox and click button then "5" empty rows will be …
Hi. I have a Windows form and when it loads focus should be on a combo box. This works correctly but the visual indicator (dotted rectangle) does not appear on the combo box though it has focus. I can confirm that the focus is there as I am able to …
namespace gridStudent { public partial class Form2 : Form { public Form2(DataGridView dgvFromFom1) { foreach (DataGridViewColumn dc in dgvFromFom1.Columns) { dataGridView1.Columns.Add(dc.Name, dc.HeaderText); } foreach (DataGridViewRow dr in dgvFromFom1.Rows) { Object[] newRow = new object[dr.Cells.Count]; for (int i = 0; i < newRow.Length; i++) { newRow[i] = dr.Cells[i].Value; } dataGridView1.Rows.Add(newRow); } …
pass the value of three textbox from one form to another form for simple windows form application
hi everyone I'd really appreciate any help i could get. I have 2 windows forms. In the first winform i have a text box and a button. In the second winform i have tab control with two tab pages. In the first winform, if a user enters the letter "a" …
Hi.....Is it possible to place live tiles or animated tiles in c# windows forms? if not what is the best way to display message when i move cursor over the button....to display message using tooltip or something like that which would be atrractive to see that message display....?? any ideas …
Hi,,,In my C# windows form, blinking and flickering occurs when i'm running the application.The form blinking occurs more times in Win 7 than Win XP.The form blinks when im opening the application and also when another form opens by button click. Can anyone tell me how to avoid that blinking …
So basically I need to create a short program that will allow the user to select "x" "y" and "z" with quanity. I know how I want the program to look "visually" but sadly I am lacking some of the elements required. I also want it to loop incase the …
so i have created a log in app which is for registering for a conference, i need the userId and userPassword from the login form to the conference form the choose this is what i have if you need further info let me know this is for the login form …
namespace Project { public partial class Chapter_Login : Form { public Chapter_Login() { InitializeComponent(); } private void btnLogin_Click(object sender, EventArgs e) { StreamReader Chapter = new StreamReader("Chapters.txt"); Chapter.ReadLine(); string[] lines = System.IO.File.ReadAllLines("Chapters.txt"); for(int i =0; i < lines.Length-1;i++) { foreach (string line in lines) { int ID = line.IndexOf("-"); int …
Hi , I m using VS2008 with SQL server 2008 at the backend. I m creating a windows application in which I have 2 listboxes.the data is being retrieved from SQL server database in listbox1.i want to select few itms from this listbox and add them to second one through …
I am desperately trying to add a DataGridViewComboBoxColumn to my DataGridView programatically. Here is the Code I've got so far. DataTable dt = new DataTable(); dt = _userBL.getUsersTable().DefaultView.ToTable(false, "Person_ID", "FirstName", "LastName", "Title", "Username"); dataGridView1.DataSource = dt; DataGridViewComboBoxColumn ComboBoxCell = new DataGridViewComboBoxColumn(); ComboBoxCell.Name = "State"; ComboBoxCell.ValueMember = "State";//ComboBoxCell.DisplayMember = "State"; ComboBoxCell.DisplayMember …
I am developing a winform application. I have menu like Edit -> Copy and Edit -> Paste. Instead of using Clipboard class to do copying and pasting can I use Operating System's ability to Copy and Paste text, image, link, etc...
Okay so I know how to close the application completely but when I have multiple forms it tends to mess up my main form and cause bugs when I close my secondary forms. Can anyone help me with this problem? [CODE]// The bug I get is in Program.cs and it …
I've got some winforms partial classes marked `[Obsolete]`. Unlike when applying this to methods, I get no warning after building. Is this because it's set on a partial class? I can't set it in the designer too, because that code can/will be regenerated. Anything I can do about it with …
I have teo form form1 and form2 i want to pass form1 textbox1 text in form2 textbox1.text whae i click a button of form1.(Its for windows application) Plz give me some help......
private void button1_Click(object sender, EventArgs e) { try { var sr = new System.IO.StreamReader("C:\\" + textBox1.Text + "\\login.txt"); username = sr.ReadLine(); password = sr.ReadLine(); email = sr.ReadLine(); sr.Close(); if (username == textBox1.Text && password == passwordtextbox.Text) MessageBox.Show("You are now successfully logged in."); else MessageBox.Show("Username or Password seems invalid, please use …
Greetings, I'm facing a problem I'm working on an existing accounting solution. In the solution there are a report for view product prices with product image. Each product has 2 images in the database. When you are about to make a product prices view to a customer first you go …
Greetings I'm making a WindowsFrom for an invoice and I'm having a problem with datagridview control that consists of two **datagridviewcombobox** columns and another two **datagridviewtextboxcolumn** First of all I build the datagridview within run-time, I mean adding its columns within run-time datagridview.columns.add(datagridviewcomboboxcolumn1); datagridview.columns.add(datagridviewcomboboxcolumn2); datagridview.columns.add(datagridviewtextboxcolumn); datagridview.columns.add(datagridviewtextboxcolumn2); I restored the product …
Hello there,,,,,,, In my project there is one window form and on that form I have one linkLabel control..... Now my question is that I want to add one web page into my project ......so that when I click on the LinkLabel it must open that web page .....so how …
I am trying to create a program in windows forms and i am almost done by my array will not store numbers. It will only use the last number entered. Please help, i did this program in c sharp without a problem but cant figure out windows forms application. public …
I have created a windows form keyboards that pops up when a button is pressed on the form. when i write from the keyboard and ok is pressed i want the text to appear in the toolstrip textbox. its sine when writing to a windows forms textbox i get the …
hi all, I want to create a very minimal explorer(no treeview) that only shows the contents of a specific folder. i made a drawing of what i want to achieve:  in the above picture, the red box represents a very minimal file explorer (square shaped) that opens only …
I'm using a TableLayoutPanel which will contain a few dynamically generated LinkLabel's I get everything except the extra spaces in 1st and 2nd row. I've attached a snapshot through screecast. Can anyone tell me how to remove this extra thing? Heres the snap shot link : http://screencast.com/t/dZqRzSZU
hi guys, i have created a datagridview with a combobox, which pulls out info from my DB, what i am trying to do now is, populate the rest of the datagridview with the information linked to the selection. failing that i want to populate a label with the selected item. …
Hey ! Someone can help me how i can close form using another form i try with this code private void button1_Click(object sender, EventArgs e) { Form1 frm = new Form1(); frm.Close(); } but its dont work !!!
Hello, I have a scenario where I fetch all the records from a database table using ADO.Net and I want to convert one of the column values which has either "0" or "1". If 0, then "No" should be replaced with 0 and if 1, then it should be "Yes". …
in windows form application,i wrote this code in enter event of textbox to add the enterd text into a listbob control.but it didnt worked. listbox1.items.add(textbox1.text); how to solve this problem.
public partial class FrmEndDateSummaryOnLoad : FrmErpSimple { List<string> mVehicleRemainderList; //SMdiForm mMdiParent; string mCurrentUserId; string mCurrentPeriodId; DataTable dataTableVehicleID = new DataTable(); DataTable dataTableVehicleNextKMS = new DataTable(); public FrmEndDateSummaryOnLoad(CErpDataConnection pErpDataConnection, CUserLoginInfo pUserLoginInfo , CRegional pRegional) : base(pErpDataConnection, pUserLoginInfo) { InitializeComponent(); } protected override void OnLoad(EventArgs e) { mCurrentPeriodId = mUserLoginInfo.GetPeriodID(); mCurrentUserId = …
hello all I wonder how to fill datagridviewimagecolumn with an icon. I mean if I place cursor in rows[2],Cells[3] and then i press right mouse down,then certain icon placed in that cells if I place cursor in rows[4],cells[3] and then press left mouse down,then another certain icon placed in that …
Hi, I have two forms, Form1, Form2 I need to show form2 first and then add form1 to form2. I did this in program.cs Passing form2 object to form1 in constructor. am assigning the properties of form2 in form1 using the constructor object. static class Program { static void Main() …
Just got to playing around, and felt that the VB forum on here could use some posts. What I was playing around with forms in VB.NET and wanted to hard code centering a form. Here is what I found...and if anyone has an easier or slicker way...let me know. -in …
I make many to many relationship in erd diagram in sql server 2005 between ca and driver as following car table driver table car_driver table. I need to make fleet management program. When I make forms in windows form are i make car form driver form car_driver form When i …
hi everyone, my question would be on how to anchor the child mdi to its parent mdi so that each time the user maximizes or minimizes the parent form the child form inside will automatically anchor itself on its container(parent mdi) thanks all help will be appriciated
How to stretch PictureBox into Maximized screen size ? Currently the size of picturebox is exactly the size of the image, I want to stretch to the resolution screen size excluding taskbar. private void Form2_Load(object sender, EventArgs e) { Form2 f2 = new Form2(); pictureBox1.Size = new System.Drawing.Size(Screen.PrimaryScreen.Bounds.Width, Screen.PrimaryScreen.Bounds.Height); }
using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.IO; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows.Forms; using System.Xml; namespace WindowsFormsApplication2 { public partial class Form1 : Form { public Form1() { InitializeComponent(); } List<Person> people = new List<Person>(); private void Form1_Load(object sender, EventArgs e) { string …
Anybody familiar with AutoVue? Am using Desktop V20.2.2 embedded in a WinForm. Am looking if it's possible to set the background color. So far I haven't found any conclusive answer whether or not this is possible.
In my project I have a Settings form and a Main form. I'm trying to call the Main form's MasterReset function from the Setting form, but nothing happens. The Main form's MasterReset function looks like this: public void MasterReset() { DialogResult dialogResult = MessageBox.Show("Are you sure you want to perform …
A modal dialog is a window that you must respond to. The MessageBox for example is such a window. It is a handy tool for displaying a warning or other kind of message to the user. But, you can configure it only in a limited way. Xcelled194 did a good …
hi I am trying to save multiple images into one ID and I am getting no where ...I am posting the code so for storing and retrieving image (one image)...but need to store more than one ....need some help here ... using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using …
I want to maximize and minimize windows form on Timer Tick evebt. I placed the code this.WindowState = FormWindowState.Minimized; into the timer tick event. but actually its not working. Suggest me some code snippet for the same. Regards, Manthan
Hi, I have [ICODE]DataTable[/ICODE]'s column that is a source of rows for combo box - it loads rows like it should. But, binding [ICODE]ComboBox.SelectedValue[/ICODE] does nothing. I think that this is some problem with comparison between the value provided by [ICODE]BindingSource[/ICODE] and the values from [ICODE]ComboBox[/ICODE]. [ICODE]BindingSource.Position[/ICODE] iterates through collumn …
hi frds, I want to check items of checked list box of one form from second form . while i put the same items in listbox at second form. I just want to check mark on checkedlist box control on form one if i select listbox item on second form. …
This has by far no practical use. But as I was used to VS, handling most of the code housekeeping "behind the back", I wanted to try to make a Forms program as minimalistic as possible. Start an Empty project, include a reference to System.Windows.Forms and fill in the code. …
Hi, I am using windows form. One of the form containing a combobox which populates data using datatable method. If the user found there is no particular data then they can add using an another form thru a button click to open and save the data. The saved data in …
Hello! I come here with a tricky question and I do not know how to code it at all. First off, I am coding in Visual Studio 2010 C# Windows Forms Application I need someone to help me code the following example: I have a text file which includes only …
I working on winform appplication.I have DataGridView.when i write 1st character in Cell,cursor automatically focus on first character.And if i write 2nd character it overwrites the 1st character.So if i need to write more characters then everytime i have to press Right Arrow key to move.Any Help Please.Thanks in Advance.
Hello! I am coding in windows form application c++/CLR I need help with coding a way to read everything in a folder, put the names of the files and put the names in a combobox. These files are for now images (.jpeg). And I would also like that, when I …
The End.