AGB  ·  Datenschutz  ·  Impressum  







Anmelden
Nützliche Links
Registrieren
Thema durchsuchen
Ansicht
Themen-Optionen

Get count of members in record

Ein Thema von nanix · begonnen am 10. Jan 2010 · letzter Beitrag vom 10. Jan 2010
Antwort Antwort
Seite 2 von 2     12   
alzaimar
(Moderator)

Registriert seit: 6. Mai 2005
Ort: Berlin
4.956 Beiträge
 
Delphi 2007 Enterprise
 
#11

Re: Get count of members in record

  Alt 10. Jan 2010, 12:27
Zitat von himitsu:
Zitat von nanix:
yea himitsu add all these functions for each record i have over 35 would be mad crazy
Well, whoever wants it easier later, you first have to invest some work.
2-3 hrs. WTF. As an alternative, replace your records by DTO this might be a bit more work but gives you the advantage of RTTY and OOP.
"Wenn ist das Nunstruck git und Slotermeyer? Ja! Beiherhund das Oder die Flipperwaldt gersput!"
(Monty Python "Joke Warefare")
  Mit Zitat antworten Zitat
nanix
(Gast)

n/a Beiträge
 
#12

Re: Get count of members in record

  Alt 10. Jan 2010, 13:03
an example would be more than welcome

thanks
  Mit Zitat antworten Zitat
alzaimar
(Moderator)

Registriert seit: 6. Mai 2005
Ort: Berlin
4.956 Beiträge
 
Delphi 2007 Enterprise
 
#13

Re: Get count of members in record

  Alt 10. Jan 2010, 14:11
Replace 'RECORD' by 'CLASS', publish or public your record fields as properties and you're almost through. You'll also be able to add some serialisation/deserialisation routines in case you need them.
"Wenn ist das Nunstruck git und Slotermeyer? Ja! Beiherhund das Oder die Flipperwaldt gersput!"
(Monty Python "Joke Warefare")
  Mit Zitat antworten Zitat
nanix
(Gast)

n/a Beiträge
 
#14

Re: Get count of members in record

  Alt 10. Jan 2010, 14:32
what about this approach


Delphi-Quellcode:
type
 TProperties = TDictionary<string,string>;
 TInstances = TDictionary<string, string>;
 TClases = TDictionary<integer, TInstances>;

 Clases := TClases.Create;

 Clases.AddOrSetValue(0, TInstances.Create);
Clases[0].AddOrSetValue('1sdfgsdfgs', 'sdfgsdfgsdfgsdfgsdfgsdfgsdfg2');
  Mit Zitat antworten Zitat
Antwort Antwort
Seite 2 von 2     12   


Forumregeln

Es ist dir nicht erlaubt, neue Themen zu verfassen.
Es ist dir nicht erlaubt, auf Beiträge zu antworten.
Es ist dir nicht erlaubt, Anhänge hochzuladen.
Es ist dir nicht erlaubt, deine Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks are an
Pingbacks are an
Refbacks are aus

Gehe zu:

Impressum · AGB · Datenschutz · Nach oben
Alle Zeitangaben in WEZ +1. Es ist jetzt 15:11 Uhr.
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz