Author Topic: Array of BYTEs  (Read 10165 times)

Offline c0d3r9

  • Community Developer
  • Prof. Inline
  • ******
  • Posts: 506
    • View Profile
Re: Array of BYTEs
« Reply #15 on: 2008-Oct-21 »
need some other commands too.

ReadBytes  (http://www.blitzforum.de/help/ReadBytes)
ReadInt      (http://www.blitzforum.de/help/ReadInt)
Ryzen 5 3400G - MSI B450 Tomahawk - 16GB DDR4

Offline Kitty Hello

  • code monkey
  • Administrator
  • Prof. Inline
  • *******
  • Posts: 10766
  • here on my island the sea says 'hello'
    • View Profile
    • http://www.glbasic.com
Re: Array of BYTEs
« Reply #16 on: 2008-Oct-21 »
OK, I added a new version which has PEEKLONG and POKELONG, too.

However! You need V6 to compile it, and the IDE currently does not display function names ending with % properly. The compiler works, however.

Offline c0d3r9

  • Community Developer
  • Prof. Inline
  • ******
  • Posts: 506
    • View Profile
Re: Array of BYTEs
« Reply #17 on: 2008-Oct-25 »
Gernot can you make this one command too?

ReadBytes (bank, stream, start, anzahl)   // read anzahl of bytes beginning at start in the file was opened.return anzahl sucessfully read bytes and writes the bytes in the bank created with CreateBank.

here german link for help : http://www.blitzforum.de/help/ReadBytes

perhaps WriteBytes too.

Start reading in the bank at start and write it to file was opened.

and useful can be resizebank and copybank.

I hope its not to much hard work for you.

Big thanks.
Ryzen 5 3400G - MSI B450 Tomahawk - 16GB DDR4

Offline Hemlos

  • To boldy go where no pixel has gone before!
  • Global Moderator
  • Prof. Inline
  • *******
  • Posts: 1645
  • Particle Hawk
    • View Profile
Re: Array of BYTEs
« Reply #18 on: 2008-Oct-25 »
ReadBytes (bank, stream, start, anzahl)   // read anzahl of bytes beginning at start in the file was opened.return anzahl sucessfully read bytes and writes the bytes in the bank created with CreateBank.


Not sure why you need something like that..

readbyte,1,dat$
dimpush bank[],dat$

Isnt this the same thing?

btw,What is anzahl?
Volume_of_Earth(km^3) = 4/3*3.14*POW(6371.392896,3)

Offline Moru

  • Administrator
  • Prof. Inline
  • *******
  • Posts: 1792
    • View Profile
    • Homepage

Offline Kitty Hello

  • code monkey
  • Administrator
  • Prof. Inline
  • *******
  • Posts: 10766
  • here on my island the sea says 'hello'
    • View Profile
    • http://www.glbasic.com
Re: Array of BYTEs
« Reply #20 on: 2008-Oct-27 »
Write to file or what?

Offline c0d3r9

  • Community Developer
  • Prof. Inline
  • ******
  • Posts: 506
    • View Profile
Re: Array of BYTEs
« Reply #21 on: 2008-Oct-27 »
yes, read out a bank at "start" with number of "anzahl" return the number of truely read datas and write it at the same time to the stream open with open file.

The same like WriteBytes wich write Bytes from a streamed file at "start" in file number of "anzahl" write to a bank created with CreateBank at position 0, i think.

Now you know?
Ryzen 5 3400G - MSI B450 Tomahawk - 16GB DDR4

Offline Kitty Hello

  • code monkey
  • Administrator
  • Prof. Inline
  • *******
  • Posts: 10766
  • here on my island the sea says 'hello'
    • View Profile
    • http://www.glbasic.com
Re: Array of BYTEs
« Reply #22 on: 2008-Oct-27 »
OK, update.

Offline c0d3r9

  • Community Developer
  • Prof. Inline
  • ******
  • Posts: 506
    • View Profile
Re: Array of BYTEs
« Reply #23 on: 2008-Oct-27 »
cool job gernot, thanks.
one question if you have anytime a little time for it.

CopyBank and ResizeBank are useful....too.

But perhaps at this time not important.
Ryzen 5 3400G - MSI B450 Tomahawk - 16GB DDR4