Autor Beitrag
Fabian
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 42



BeitragVerfasst: Do 25.07.02 15:18 
Hallo,
Wie kann ich das letzte Zeichen eines Strings löschen ?
Klabautermann
ontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic starofftopic star
Veteran
Beiträge: 6366
Erhaltene Danke: 60

Windows 7, Ubuntu
Delphi 7 Prof.
BeitragVerfasst: Do 25.07.02 15:56 
Hallo,
eine Möglichkeit sieht so aus:

ausblenden Quelltext
1:
MyString := copy(MyString, 1, length(MyString ) - 1);					


Gruß
Klabautermann
Alibi
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 458

Win2K SP3
Delphi 6 Ent
BeitragVerfasst: Do 25.07.02 16:43 
Mit den delete und length Funtionen wirst du das *schaffen*.
hitstec
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 295



BeitragVerfasst: Do 25.07.02 18:24 
Ja, du schaffst das :lol: :

ausblenden Quelltext
1:
Delete(DeinString,Length(DeinString)-1,1);					
Chatfix
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 1583
Erhaltene Danke: 10

Win 10, Win 8, Win 7, Win Vista, Win XP
VB.net (VS 2015), MsSQL (T-SQL), HTML, CSS, PHP, MySQL
BeitragVerfasst: Sa 27.07.02 01:31 
Besser kann mans ja gar nicht erklären fg.. entweder mit copy oder halt mit delete, das ergebnis is das gleiche nur die funktionsweise unterscheidet sich halt ein bissl *fg*

_________________
Gehirn: ein Organ, mit dem wir denken, daß wir denken. - Ambrose Bierce