Værsgo en strType. Virker til delphi og turbo pascal.
Unit Strtype;
Interface
Type
Str1 = String[1];
Str2 = String[2];
Str3 = String[3];
Str4 = String[4];
Str5 = String[5];
Str6 = String[6];
Str7 = String[7];
Str8 = String[8];
Str9 = String[9];
Str10 = String[10];
Str11 = String[11];
Str12 = String[12];
Str13 = String[13];
Str14 = String[14];
Str15 = String[15];
Str16 = String[16];
Str17 = String[17];
Str18 = String[18];
Str19 = String[19];
Str20 = String[20];
Str21 = String[21];
Str22 = String[22];
Str23 = String[23];
Str24 = String[24];
Str25 = String[25];
Str26 = String[26];
Str27 = String[27];
Str28 = String[28];
Str29 = String[29];
Str30 = String[30];
Str31 = String[31];
Str32 = String[32];
Str33 = String[33];
Str34 = String[34];
Str35 = String[35];
Str36 = String[36];
Str37 = String[37];
Str38 = String[38];
Str39 = String[39];
Str40 = String[40];
Str41 = String[41];
Str42 = String[42];
Str43 = String[43];
Str44 = String[44];
Str45 = String[45];
Str46 = String[46];
Str47 = String[47];
Str48 = String[48];
Str49 = String[49];
Str50 = String[50];
Str51 = String[51];
Str52 = String[52];
Str53 = String[53];
Str54 = String[54];
Str55 = String[55];
Str56 = String[56];
Str57 = String[57];
Str58 = String[58];
Str59 = String[59];
Str60 = String[60];
Str61 = String[61];
Str62 = String[62];
Str63 = String[63];
Str64 = String[64];
Str65 = String[65];
Str66 = String[66];
Str67 = String[67];
Str68 = String[68];
Str70 = String[70];
Str71 = String[71];
Str72 = String[72];
Str73 = String[73];
Str74 = String[74];
Str75 = String[75];
Str76 = String[76];
Str77 = String[77];
Str78 = String[78];
Str79 = String[79];
Str80 = String[80];
Str81 = String[81];
Str82 = String[82];
Str83 = String[83];
Str84 = String[84];
Str85 = String[85];
Str86 = String[86];
Str87 = String[87];
Str88 = String[88];
Str89 = String[89];
Str90 = String[90];
Str91 = String[91];
Str92 = String[92];
Str93 = String[93];
Str94 = String[94];
Str95 = String[95];
Str96 = String[96];
Str97 = String[97];
Str98 = String[98];
Str99 = String[99];
Str100 = String[100];
Str101 = String[101];
Str102 = String[102];
Str103 = String[103];
Str104 = String[104];
Str105 = String[105];
Str106 = String[106];
Str107 = String[107];
Str108 = String[108];
Str109 = String[109];
Str110 = String[110];
Str111 = String[111];
Str112 = String[112];
Str113 = String[113];
Str114 = String[114];
Str115 = String[115];
Str116 = String[116];
Str117 = String[117];
Str118 = String[118];
Str119 = String[119];
Str120 = String[120];
Str121 = String[121];
Str122 = String[122];
Str123 = String[123];
Str124 = String[124];
Str125 = String[125];
Str126 = String[126];
Str127 = String[127];
Str128 = String[128];
Str129 = String[129];
Str130 = String[130];
Str131 = String[131];
Str132 = String[132];
Str133 = String[133];
Str134 = String[134];
Str135 = String[135];
Str136 = String[136];
Str137 = String[137];
Str138 = String[138];
Str139 = String[139];
Str140 = String[140];
Str141 = String[141];
Str142 = String[142];
Str143 = String[143];
Str144 = String[144];
Str145 = String[145];
Str146 = String[146];
Str147 = String[147];
Str148 = String[148];
Str149 = String[149];
Str150 = String[150];
Str151 = String[151];
Str152 = String[152];
Str153 = String[153];
Str154 = String[154];
Str155 = String[155];
Str156 = String[156];
Str157 = String[157];
Str158 = String[158];
Str159 = String[159];
Str160 = String[160];
Str161 = String[161];
Str162 = String[162];
Str163 = String[163];
Str164 = String[164];
Str165 = String[165];
Str166 = String[166];
Str167 = String[167];
Str168 = String[168];
Str169 = String[169];
Str170 = String[170];
Str171 = String[171];
Str172 = String[172];
Str173 = String[173];
Str174 = String[174];
Str175 = String[175];
Str176 = String[176];
Str177 = String[177];
Str178 = String[178];
Str179 = String[179];
Str180 = String[180];
Str181 = String[181];
Str182 = String[182];
Str183 = String[183];
Str184 = String[184];
Str185 = String[185];
Str186 = String[186];
Str187 = String[187];
Str188 = String[188];
Str189 = String[189];
Str190 = String[190];
Str191 = String[191];
Str192 = String[192];
Str193 = String[193];
Str194 = String[194];
Str195 = String[195];
Str196 = String[196];
Str197 = String[197];
Str198 = String[198];
Str199 = String[199];
Str200 = String[200];
Str201 = String[201];
Str202 = String[202];
Str203 = String[203];
Str204 = String[204];
Str205 = String[205];
Str206 = String[206];
Str207 = String[207];
Str208 = String[208];
Str209 = String[209];
Str210 = String[210];
Str211 = String[211];
Str212 = String[212];
Str213 = String[213];
Str214 = String[214];
Str215 = String[215];
Str216 = String[216];
Str217 = String[217];
Str218 = String[218];
Str219 = String[219];
Str220 = String[220];
Str221 = String[221];
Str222 = String[222];
Str223 = String[223];
Str224 = String[224];
Str225 = String[225];
Str226 = String[226];
Str227 = String[227];
Str228 = String[228];
Str229 = String[229];
Str230 = String[230];
Str231 = String[231];
Str232 = String[232];
Str233 = String[233];
Str234 = String[234];
Str235 = String[235];
Str236 = String[236];
Str237 = String[237];
Str238 = String[238];
Str239 = String[239];
Str240 = String[240];
Str241 = String[241];
Str242 = String[242];
Str243 = String[243];
Str244 = String[244];
Str245 = String[245];
Str246 = String[246];
Str247 = String[247];
Str248 = String[248];
Str249 = String[249];
Str250 = String[250];
Str251 = String[251];
Str252 = String[252];
Str253 = String[253];
Str254 = String[254];
Str255 = String;
const
Tal_set : Set Of Char = ['0'..'9'];
Tal2_set : Set Of Char = ['0'..'9','*'];
Decimal : Set Of Char = ['0'..'9','.',','];
Edittal : Set Of Char = ['0'..'9','.',',','-','+'];
Bogstav : set of char = ['a'..'z','‘','›','†','A'..'Z','’','','','0'..'9'];
Ingen : Set Of Char = [];
Alle : Set Of Char = [#0..#255];
Tegn : Set Of Char = [#32..#255];
JN : Set Of Char = ['j','J','n','N'];
YN : Set Of Char = ['y','Y','n','N'];
Term : Set Of Char = [^I,#10,#13,#15,#27,#224..#244];
Termidr : Set Of Char = ['a','A','b','B','f','F','g','G','h','H','s','S'];
Ja : Set Of Char = ['j','J'];
Yes : Set Of Char = ['y','Y'];
Nej : Set Of Char = ['n','N'];
No : Set Of Char = ['n','N'];
TykStr = True;
TyndStr = False;
Op = True;
Ned = False;
On = True;
Off = True;
Hex_Tal : Array[0..15] Of Char = '0123456789ABCDEF';
Bin_Tal : Array[0..15] Of Str4 = ('0000','0001','0010','0011',
'0100','0101','0110','0111',
'1000','1001','1010','1011',
'1100','1101','1110','1111');
Dag_Navn : Array[0..7] Of Str9 = ('S›ndag','Mandag','Tirsdag',
'Onsdag','Torsdag','Fredag',
'L›rdag', 'S›ndag');
Dag_Navn2 : Array[0..7] Of Str4 = ('S›n','Man','Tir','Ons','Tor','Fre','L›r','S›n');
Maaned_Navn : Array[0..12] Of Str9 = (' ', 'Januar','Februar','Marts',
'April', 'Maj', 'Juni', 'Juli',
'August', 'September', 'Oktober',
'November', 'December');
Maaned_Navn2 : Array[0..12] Of Str3 = (' ','JAN','FEB','MAR','APR','MAJ','JUN',
'JUL','AUG','SEP','OKT','NOV','DEC');
Screen_Navn : Array[0..3] Of Str10 = ('EGA/VGA', 'CGA 40col','CGA 80col','Monochrome');
Floppy_Navn : Array[0..5] Of Str11 = ('Ingen','5.25" 360K','5.25" 1.2M', '3.5" 720K',
'3.5" 1.44M', '3.5" 2.88M');
Type
Charset = SET OF Char;
CharType = Record
Ch : Char;
Dobbelt : Boolean;
End;
datotype = Record
Dag : Word;
Maaned : Word;
Aar : Word;
Dag_I_Uge : Word;
End;
TimeType = Record
Timer : Word;
Minut : Word;
Sekund : Word;
Sek100 : Word;
End;
DegreeType = Record
Degrees : Real;
Minutes : Real;
Seconds : Real;
End;
Proc = Procedure;
PositionType = Record
X1 : Byte;
X2 : Byte;
Y1 : Byte;
Y2 : Byte;
End;
{$IFDEF Use8087}
Float = Extended;
{$ELSE}
Float = Real;
{$EndIF}
CMOS_Type = Record
Found : Boolean; { was a CMOS found to exist }
CmosDate : Str30; { the date found in CMOS }
CmosTime : Str30; { the time found in CMOS }
VideoType : Str10; { Type of video found in CMOS }
Coproc : Boolean; { does CMOS report a math coprocessor }
FloppyA : Str12; { type of floppy drive for A }
FloppyB : Str12; { Type of floppy drive for B }
Hard0 : Byte; { Type of hard drive for drive 0 }
Hard1 : Byte; { Type of hard drive for Drive 1 }
ConvenRam : Word; { amount of conventional ram indicated }
ExtendRam : Word; { amount of extended Ram indicated }
CheckSum : Boolean; { Did checksum pass }
End; { CMOS Rec }
{ Disk Type }
DirType = Record
Bibliotek : Str80;
Fornavn : Str8;
Efternavn : Str4;
End;
DiskId_Type = Record
InfoLevel : Word; {should be zero}
Serial : Longint;
VolLabel : Array[0..10] Of Char;
FileSystem : Array[0..7] Of Char;
End;
DiskVolume_Type = Record
FCB_Flag : Byte;
Reserved : Array [1..5] of Byte;
FileAttr : Byte;
Drive_ID : Byte;
FileName : Array [1..8] of Byte;
File_Ext : Array [1..3] of Byte;
Unused_A : Array [1..5] of Byte;
File_New : Array [1..8] of Byte;
FExt_New : Array [1..3] of Byte;
Unused_B : Array [1..9] of Byte;
End;
Disk_Oplysning_Type = Record
DosVersion : Real;
SectorsPerCluster : Word;
AvailClusters : Word;
BytesPerSector : Word;
TotalClusters : Word;
ClusterByte : Word;
Disk_Storrelse : Longint;
Fri_Storrelse : Longint;
End;
Drev_Type = Array['A'..'Z'] Of Boolean;
implementation
End.