blah blah blah is here! blah blah » Close

1
votes
1 answers

Close form on datagrid status

How can i close my form if my datagrid has no rows? or rows with any data anyhow. I'm going to place the code in a timer event. So basicly when my timer event fires if it doesn't count any rows in DataGridview the form will close.

1
votes
1 answers

Colot datagrid text on cell value asp.net

Guys, how do i change the text forecolor on the status in the datagrid cell? I have this working fine on a windows form app, but in the world of asp.net this is slightly different to me. I'm assuming i use the code in the Default.aspx.cs fi ...

1
votes
1 answers

Show form on status in datagrid

Guys, i hope i make sense with this question. I have a small app that will be running all the time but the form will be minimized or hidden, now i have a DataGrid1 with a status column. the datagrid refreshes every few minutes, when the wor ...

1
votes
1 answers

Counting rows

Guys, I want to count the rows on my datagrid but counting -1. for example if i had 1 row in my datagrid i want label1 to display 0 I'm using the code below, it counts correct but i cant adapt it to count -1? am I missing something si ...

0
votes
2 answers

Handle null value

I'm carrying a value from one form to another, it nearly works but i'm getting the following error: System.NullReferenceException was unhandled The line of code throwing the error is: [code]NewApp.textBox1.Text = ap.ResourceIndex.ToSt ...

1
votes
1 answers

Count double values in Datagridview rows

Guys, on form load i count my datagridview rows that only contain the status "UPREPD USED" and display the total on a label, it works fine. My problem is i now want to count the rows that contain the status "UPREPD USED&qu ...

1
votes
1 answers

Custom timer event

Guys, not sure if this can be done but this is my situation: I'am using a timer event to refresh entries from a database on a local server to populate my application, now the fefresh is every 10 mins. If the server or connection should b ...

0
votes
3 answers

Parse DateTime Exact

How can i parse the below datetime as exact? [code]DateTime dt = DateTime.Parse(row.Cells[2].Value.ToString());[/code] when the above code is executed i get error: 'String was not recognized as a valid DateTime.' the format of the ...

1
votes
3 answers

Count datagrid rows that contain a value

Guys this may be a simple answer, but i can't get it to work how i want. Example: the following code counts the rows in my datagrid and it counts them fine: [code]label6.Text = (usedDataGridView.Rows.Count - 1).ToString();[/code] Now ...

1
votes
2 answers

Change backcolor on datagridview

I have a datagridview with a column called "status" that loads a value from a database, i'm trying to change the back color of the row to yellow if there's the value of "cleaned" in the 'status' column. I'll put the f ...

1
votes
1 answers

Datagridview cell content click

Guys, I'm trying to add an event to a datagridview cell content click for when a user clicks a cell row it changes a value on that row. Example my datagridview on colunm [2] has the word "start" i want the user to click the cel ...

2
votes
1 answers

Count Rows in Datagridview

I'm trying to count the rows on my datagridview and display the number of rows on "label1" what's the best way to do this? i was going to drop the code in the form load event. Also i only want to count rows with text in, as dat ...

1
votes
2 answers

Check for existing entries and throw a message

I'm trying to compile some code that will check if a date from a datetimepicker and text from a textbox match exisisting entries in a datagridview if so throw a message window. Example: on my form i have dateTimePicker1 and resIndexTe ...

0
votes
2 answers

Fire event from button click

Guys, is it possible to fire an event on the form from a button click, i want to call the below event if possible? [code]private void comboCalendar_AppointmentChanged(object sender, ComponentGo.Calendars.AppointmentEventArgs args) ...

1
votes
2 answers

Report viewer printing

Guys, is there a way to print Microsoft report viewer direct to the default printer without using the print dialog window? my button click contains: [code]//this works but only by manually choosing printer reportViewer1.PrintDialog();[ ...

Feedback