ERLEDIGT
NEIN
NEIN
ANTWORTEN
1
1
ZUGRIFFE
1097
1097
EMPFEHLEN
-
Hallo Leute,
ich möchte in einer Listview ein Item durch ein anderes ersetzten.
string[] Spalte = new string[2];
Spalte[0] = name;
Spalte[1] = Status;
listView1.Items.Insert(position, new ListViewItem(Spalte));
listView1.Items.RemoveAt(position+1);
Doch jetzt springt der Focus immer auf das nächste Element.
Wie kann ich ein Item ersetzten und dass der Focus auf dem Item bleibt
Das hab ich schon versucht hat aber nicht funktioniert:
listView1.Items[position].Focused = true;
listView1.Items[position].Selected = true;
Evtl. hab ich ne falsche Reihenfolge.
Kann mir jemand helfen
MfG
-
09.01.04 21:39 #2
- Registriert seit
- Aug 2001
- Ort
- Österreich, Stmk, Graz
- Beiträge
- 2.783
Hallo.
Code :1 2
listView1.Select(); listView1.Items[position].Selected = true;
Auf diese Art und Weise funktioniert es bei mir.
Mfg,
Alex
// Edit: Muss man ja erwähnen, 500.
With the first link the chain is forged. The first speech censored, the first thought forbidden, the first freedom denied, chains us all irrevocably.
Aaron Satie
Legends... are the spice of the universe, Mr. Data, because they have a way of sometimes coming true.
Captain Jean-Luc Picard, Stardate ~41294.5
Tutorials.de chattet. Hier gibts auch .net Support ^^
Klickt auf chattet und nutzt den Webchat, oder verbindet euch zu irc.tutorials.de - Channel #Tutorials.de
(moo)blog furred.net // SiteInfo für WP7 // Pastebin für WP7 // BlogEngine.net Extensions
Ähnliche Themen
-
Listview
Von stroemi2 im Forum Visual Basic 6.0Antworten: 0Letzter Beitrag: 21.02.09, 10:45 -
ListView
Von devlin im Forum Visual Basic 6.0Antworten: 9Letzter Beitrag: 09.12.03, 08:44 -
ListView & XML
Von Tüv-Killer im Forum .NET ArchivAntworten: 2Letzter Beitrag: 31.10.03, 15:37 -
-->VB.Net ListView
Von Silverado im Forum Visual Basic 6.0Antworten: 0Letzter Beitrag: 21.07.03, 12:39 -
ListView ... VB.NET
Von Udo im Forum Visual Basic 6.0Antworten: 4Letzter Beitrag: 15.12.02, 18:36





Zitieren

Login





