Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / What ARE all these types?

Author
Message
Rwilson
23
Years of Service
User Offline
Joined: 19th May 2003
Location: United States
Posted: 26th Sep 2003 05:32
This is something of a spawn-off of my Read File problem. I was sitting there, trying to understand the problem, digging through the help, and realized there's quite a few Data Types and Save/Read Types that I have absouloutly no idea what they are used for. I would deeply appreciate explanations as to what they do, and what one would use them for.

Write and Read Types
Write/Read Byte
Write/Read Word
Write/Read Long
Write/Read DirBlock
Write/Read FileBlock
Write/Read File

Data Types
Word
Dword
Double Integer
Double Float
JoelJ
22
Years of Service
User Offline
Joined: 8th Sep 2003
Location: UTAH
Posted: 26th Sep 2003 06:03
double int and double float hold more decimal places i belive. float, goes to the nearest. ex - 1.947 instead of 1.94700000000000.

<{^_^<}
Rwilson
23
Years of Service
User Offline
Joined: 19th May 2003
Location: United States
Posted: 26th Sep 2003 06:07
Yes, I had noticed this, but why not allow a regular int and float do the same, without creating a new data type?
Shadow Robert
23
Years of Service
User Offline
Joined: 22nd Sep 2002
Location: Hertfordshire, England
Posted: 26th Sep 2003 08:36
its so you have more control over the data you use

Write/Read Byte : 1Byte : 0..255 / -127..128
Write/Read Word : 2Byte : 0..65,535 / -32,767..32,768
Write/Read Long : 4Byte : 0..4,294,967,296 / -2,147,483,647..2,147,483,648
Write/Read DirBlock : 1Byte : String Directory Attribute
Write/Read FileBlock : n|a : Complete File
Write/Read File : Same as Long

you also forgot string and float

-- --

Boolean : 0.125 Byte : 0..1
Byte : 1Byte : 0..255 / -127..128
Word : 2Byte : 0..65,535 / -32,767..32,768
Dword : 4Byte : 0..4,294,967,296 / -2,147,483,647..2,147,483,648
Float : 4Byte : 23 Static 8 Exponencial, which is complicated but kinda simply means a 15 digit number
Double Integer : 8Byte : 0..8,589,934,592 / -4,294,967,295..4,294,967,296
Double Float : 48 Static 14 Exponencial, against simply means to 32 digit number
String : 4 Byte expansive character string (used to be upto 255 characters)

Rwilson
23
Years of Service
User Offline
Joined: 19th May 2003
Location: United States
Posted: 26th Sep 2003 15:49
ah, so it's all for differnet size numbers for the most part. Also seems to be a memory issue, what with the different byte sizes. Thank you, Raven.

Login to post a reply

Server time is: 2026-07-25 08:28:59
Your offset time is: 2026-07-25 08:28:59