I'm about to make a small application Windows Form/C# to keep different kind of informations such as passwords credit card info etc.
It is rather simple with a treeview on the left side and a listview on the right side.
Now I implement 'Search' and 'Find next' and it works fine so far in both views. However when I find and highlight a hit in a listview subitem the entire cell (background) is highlighted but I only want to highlight the text itself.
(I would like to add some screen shots but I don't know how to do it).
Any ideas how to solve this (code example are very much appreciated)?
Thanks for your reply. I have already had a look at ObjectListView but I discarded it because it also carries a lot of code that I do not need - I hoped for something more simple.
But you may be right that it is no other alternatives to do a lot of hard coding myself.
Anyway I will once again consider to use it.
Yeah, it is a rather heavy control. But I cut out about 65% of the code in the application I was using it for, so that is a big win. (Yes, 65% of the code was for handling list view related operations, and I was only about 30% done with the program!)
What do you get when you cross a joke with a rhetorical question?
The metaphorical solid rear-end expulsions have impacted the metaphorical motorized bladed rotating air movement mechanism.
Do questions with multiple question marks annoy you???
Hey, I am new to GUI programming
While trying to design a dialog box that gets user input and saves it to a file on clicking the save button, I ran into this error.
public class Mfury : Form
Size = new Size(800,500);
Text = "Enter details of the book";
Label xo = new Label();
xo.Text = "Name : ";
xo.Location = new Point(10,10);
xo.Width = 50;
xo.Parent = this;
TextBox to = new TextBox();
to.Parent = this;
to.Location = new Point(90,10);
to.Width = 600;
to.Multiline = false;
string Var1 = to.Text;
Label x1 = new Label();
x1.Text = " ISBN : ";
x1.Width = 50;
x1.Location = new Point(10,50);
x1.Parent = this;
TextBox t1 = new TextBox();
t1.Parent = this;
t1.Location = new Point(91,43);
t1.Width = 600;
t1.Multiline = false;
string Var2 = t1.Text;
Label x2 = new Label();
x2.Text = "Key Words :";
x2.Width = 80;
x2.Parent = this;
x2.Location = new Point(10,90);
TextBox t2 = new TextBox();
t2.Parent = this;
t2.Location = new Point(91,83);
t2.Width = 600;
t2.Multiline = false;
string Var3 = t2.Text;
Button bo = new Button();
Button b1 = new Button();
bo.Parent = this;
b1.Parent = this;
bo.Location = new Point(520,350);
bo.Text = "Save";
bo.Height = 100;
bo.Width = 100;
b1.Location = new Point(630,350);
b1.Text = "Close";
b1.Size = new Size(100,100);
bo.Click += new EventHandler(onsave);
b1.Click += new EventHandler(onExit);
void onsave(Object Sender,EventArgs e)
FileStream fs = new FileStream("test.txt",FileMode.OpenOrCreate,FileAccess.Write);
StreamWriter sw = new StreamWriter(fs);
void onExit(Object Sender,EventArgs e)
public static void Main()
What error, and where does it occur? Also, please use <pre> tags around your code, not [code]. You can do it automatically by selecting all the lines in your post, and using the code button at the top of the edit box.
An easy idea would be, "you need to create a variable with that name, or you need to see if variable name has any typos".
Secondly, as already mentioned. [code][\code] is supported on some websites, such as Quora. On CodeProject, you have to embed your code inside <pre> tags, or you can try out using the new Markdown[^] on CodeProject.
The sh*t I complain about
It's like there ain't a cloud in the sky and it's raining out - Eminem
~! Firewall !~
Hi, I have a gridview where the first column is a checkbox. When I open the grid, the value of the first checkbox is always false, no matter how it is initialized. When I select another cell, the correct state appears. How could I have the correct value be shown?
Hopefully I am posting in the right place otherwise please correct me.
I want to display a scrollable list of tiles with images to display categories of items (all click selectable) and have another area displaying products as images all click selectable. I want to do this in C# .net 4.0 using VS 2010.
I would like advice on which controls to use from the basics (non commercial please). Could someone please point me in the right direction.
Hey guys, we are trying to design an autonomous system to match the criteria between college students qualifications and the companies offering intern positions requirements, I have checked and the closest thing I got were a few CRM's. If any of you have any idea about any open source software that we can use to design such a system please share your knowledge on the matter
this i my first post, so i hope i am explaining it correctly, have a datagridview with a textboxcolumn. it is bind to a dataset
my problem is when i update a record wiht more that 350 characters it give me a nullrefference error. the database is updated when i check the physical record but the application crash
here is the function
Private Sub m_maintenanceProcessor_WebsiteUpdated(ByVal sender As Object, ByVal e As Processors.EventArgs) Handles m_maintenanceProcessor.WebsiteUpdated
Dim tempTable As MaintenanceDataSet.WebsitePageDownloadDataTable
If e.Data.Contains("ModifiedRows") = False Then Exit Sub
tempTable = CType(e.Data("ModifiedRows"), MaintenanceDataSet.WebsitePageDownloadDataTable)
If tempTable.Rows.Count > 0 Then
RemoveHandler maintenanceDataGridView.RowValidated, AddressOf maintenanceDataGridView_RowValidated
Processor.Data.WebsitePageDownload.LoadingTable = True
Processor.Data.WebsitePageDownload.LoadingTable = False
AddHandler maintenanceDataGridView.RowValidated, AddressOf maintenanceDataGridView_RowValidated
'For Each row As DataRow In tempTable.Rows
' If row.RowError IsNot Nothing AndAlso row.RowError.Length > 0 Then
' End If
' ' MsgBox(row("URL").ToString)
Catch ex As Exception
tempTable = Nothing