Autor Beitrag
gamoes
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 86



BeitragVerfasst: Do 24.07.08 14:57 
Hallo,
habe ein Programm mit einigen DB-Edit-Feldern und einigen DBComboboxen.
Wenn ich nun einen neuen Datensatz einfügen will, soll der Anwender auf den Button neu klicken und ich will gleichzeitig einige der Felder mit Text vorbelegen, so auch die DBComboBox.
mit
db_strasse.text='Friedrichstraße'
geht es leider nicht.

Wäre dankbar, wenn ihr mir weiter helfen könntet.

Viele Grüße
Gabi
der Berliner
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 417

Win Xp Home
delphi 2005
BeitragVerfasst: Sa 02.08.08 18:31 
Hi
Also wenn schon Items in der DBComboBox eingetragen sind dann mit:

ausblenden Delphi-Quelltext
1:
2:
DBComboBox1.ItemIndex := 5
// Wenn "Friedrichstraße" z.b. an 6 Stelle deiner Itemsliste Steht


gruß Andre

_________________
[b]Ich weiß nicht immer, wovon ich rede. Aber ich weiß, dass ich recht habe.[b]
gamoes Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 86



BeitragVerfasst: So 03.08.08 18:07 
Besten Dank, so klappt es.

Gruß
Gabi