|
TwoFaced wrote: Then to add an item to the next column you would use this:
item.SubItems.Add(SubItem)
That's basically what you need to know.
THANKS Again
Have just been doing some more reading about Listview Boxs and have just figured out that what you have said is what i need to do.;)
|
|
|
|
|
This is my Code so far.....
Do While Not FileReader.EndOfStream
StringReader = FileReader.ReadLine
Form2.ListView1.Items.Add(StringReader)
'Adding Subitems
Dim item As ListViewItem = Form2.ListView1.Items.Add(StringReader)
Dim i As Integer
For i = 0 To 5
item.SubItems.Add(StringReader)
Next
Loop
Just a little bit of fine tuning....
What is happening is that the first item on the left is in the right spot, after that what should be the first sum-item it duplicated in the left column.
Then in the 3rd row this same item is in all the sub-item columns.
And the same thing happens to all the other sum-items, which then knoks out of wack all the other data.
It is surprising how writing something out and then thinking about it , you can come up with an answer;)
AND THE ANSWER is :-
move the Stringreader line into the for next loop and get rid of the line :-
Form2.ListView1.Items.Add(StringReader) as you don't need it twice in the code.
-- modified at 5:52 Monday 12th February, 2007
|
|
|
|
|
Can PDA support USB devices?? Such as fingerprint reader.
|
|
|
|
|
I doubt it, since it would probably be another drain on the battery. Check the specs on the one you're looking at. The bigger problem would be are there USB devices out there that support being attached to a PDA...
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
I am populating a windows form from btn but i want to hide the form the button is on, and when i close the existing form i bring back original form. hope this makes sense
Regards
big al
|
|
|
|
|
The easiest way to do this, is to write both forms as controls, put both controls on your one form, and change which control is visible. The other way, is just to set the initial form's Visible property to false when you open the form, and true when it's closed again.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
You could also consider setting the opacity of the form to 0% if hiding and re-showing the form causes problems wih Form_Activate if you are using it.
David Loring
!! Keep Music Live !!
|
|
|
|
|
so the form that needs to show when you close the other form place it like master form like startup form and then type this in load event in that form:
dim f as new form2()
me.hide()
f.showdialog()
me.show()
thats all...
but if you want to show form only if button is clicked then place on other form form2 one checkbox name it "chx" and type like this...
FORM 2
--------------------
public sub button1.click .... ' example button close form
chx.checked=true
me.close
end sub
public sub button2.click .... ' example button end program
chx.checked=false
me.close
end sub
-----------------------
FORM 1 STarting form
-----------------------
dim f as new form2()
me.hide()
f.showdialog()
if f.chx.checked=true then
me.show
else
end
end if
like that enyoj and hope it helps....
|
|
|
|
|
|
please describe wt u want
Lxcite's Planet
... the ultimate solution
|
|
|
|
|
Hari Om Prakash Sharma wrote: please describe wt u want
he described it up there ^ Hide Form & hiding form
|
|
|
|
|
Hi, Working with VB Net (2003) . How to highlight the Data Grid line when they are selected with a click from buttons First, Next, Previous, Last and is it possible also when I click in a cell from the same Data Grid to highlight the row. Thank you
|
|
|
|
|
Are you talking about a Windows Forms DataGrid or the Web Forms DataGrid?
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Sorry my mistake .It is a Windows Forms DataGrid
|
|
|
|
|
Hello,
I would like to know if its possible to close internet ports( port 80) in vb.net
Thanks
Al968
Avast Antivirus-<url>http://www.avast.com<url>
|
|
|
|
|
If you mean like a firewall does, then no. It takes driver level code to do this. Something that VB.NET, or managed code in general, is not suited for.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
OK Thanks
Could you specify which language you are refering to ?
Thank You
Al968
Avast Antivirus-<url>http://www.avast.com<url>
|
|
|
|
|
VB.NET, C#, ... About the only language that doesn't target the .NET Framework natively (Managed Code) is Visual C++.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
ok thanks
Al968
Avast Antivirus-<url>http://www.avast.com<url>
|
|
|
|
|
Does anyone know if there is a VB.NET version of the Threed Controls, or how you can create a label / panel with embossed or inset text?
David Loring
!! Keep Music Live !!
|
|
|
|
|
Hello guys
an error occured while i was choosing a picture within a picture box
the error is :
item with same key has already been adding
I cant add an image to my project,not even background image for a form
I always get the above error
but if i try to add a pic by code..it works fine
Note : if i open an other Project and try to add a picture,everything goes fine
Even if i copy this solution to another PC ,same problem persists
Regards
Ramy
Regards
Ramy
|
|
|
|
|
I am using "Viusal Basic Express 2005"
I was wondering how I can display the webcam picture (source) in a form
I am lost and out of control
I don't know where top begin I've search google many many times
I even tried including words that don't exist
help mee
thankyou
|
|
|
|
|
|
The question I am asking doesn't specificly aplly to a browser. The question is :
How can I set my program to run code when at any point the user presses the enter key ??
Thanks
Al968
Avast Antivirus-<url>http://www.avast.com<url>
|
|
|
|
|
Use the forms KeyPress event
also set the forms keypreview property to true
Private Sub Form1_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs)
If Char.IsControl(e.KeyChar) Then
If e.KeyChar.Equals(Chr(Keys.Return)) Then
'Your Code Here
End If
End If
End Sub
-- modified at 22:12 Saturday 10th February, 2007
|
|
|
|