Autor Beitrag
noidic
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 851

Win 2000 Win XP Vista
D7 Ent, SharpDevelop 2.2
BeitragVerfasst: Mi 31.08.05 15:06 
Es soll also beim Doppelklick direkt geändert werden?

Da gibts zwei möglichkeiten:

Wenn deine Datenkomponente von TDataset abgeleitet ist ( also TQuery etc. ), kannst du mit der Befehlsfolge

ausblenden Delphi-Quelltext
1:
2:
3:
<Dataset>.edit;
<Dataset>.FieldByName( '<Feldname>' ).as<Typ> := Wert;
<Dataset>.post;


den Wert ändern.

Wenns damit nicht geht ( z.B. bei gejointen Abfragen ) holst du dir die ID aus dem entsprechenden Feld und setzt ein Update-Statement ab. Danach halt ncoh die Datenmenge refreshen.

_________________
Bravery calls my name in the sound of the wind in the night...
bs-Hobbit
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 46

Windows Xp (Home/Prof.), Windows Server 2003, Linux
D7,D2005
BeitragVerfasst: Mi 31.08.05 15:16 
Alles klar, danke für die Hilfe, ich werde mich da gleich/morgen mal ransetzten ;) ich mach in 45 min schluss hier, und habe nicht mehr soviel lust, weil da noch soviel anderes jetzt offen ist, und ich das erstmal machen werde !

DANKE DANKE

Habe folgenden code für die typen meines Programms:

ausblenden volle Höhe Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
Const
  CText = 255;
  CLongText = 512;

Type
  //Länge des textes in einem Feld
  TText = 1..CText;
  TLongText = 1..CLongText;

  TTextArray = Array[TText] Of Char;
  TLongTextArray = Array[TLongText] Of Char;

  TFormate = (Textdatei, Excel);

  // An welcher stelle welche information gespeichert ist
  TPosition = Record
                ArtNr:Byte;
                MatchCode:Byte;
                Bezeichnung:Byte;
                Einheit:Byte;
                Text:Byte;
                Warengruppe:Byte;
                Preis:Byte;
              end;
  //Informationen, über den Artikel, den Der anbieter anbietet ^^
  TArtikelInfo = record
                    Name:TTextArray;
                    DateiFormat:TFormate;
                    PosFelder:TPosition;
                  end;

  TAnbieterP = ^TAnbieter;

  TAnbieter = Record
                Value:TArtikelInfo;
                Next:TAnbieterP;
              end;

  TTextDatei = File Of TArtikelInfo;


Kann man den Array of Char auch noch anders umgehen ? (String geht net, weil das eine Typisierte datei ist)

Moderiert von user profile iconTino: Beiträge zusammengefasst.
Moderiert von user profile iconTino: Code- durch Delphi-Tags ersetzt.
noidic
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 851

Win 2000 Win XP Vista
D7 Ent, SharpDevelop 2.2
BeitragVerfasst: Mi 31.08.05 15:31 
Das gehört nicht wirklich zum Thema, oder? Dann bitte auch neuen Thread dafür machen.

_________________
Bravery calls my name in the sound of the wind in the night...