Fermer I. aldweb

Fermer II. Gratuitiels PC

Fermer III. Gratuitiels Palm

Fermer IV. Partagiciels Palm

Fermer V. iziBasic Palm

Fermer VI. Connaissance Palm

Fermer VII. Ordinateur Poche

Fermer VIII. miniPortail

Spécial !

Version mobile
de l'aldweb Site

Ni Français, ni Anglais ?

Essayez donc l'un de ces drapeaux :
[de] [es] [it] [pt]

Météo / Spam / www

Météo Lyon

aldweb contre le SPAM

Pour avoir des nouvelles de ce site, inscrivez-vous à notre Newsletter.
Se désabonner
298 Abonnés
Sites web de la famille

Webmaster - Infos
News Amis


   visiteurs en ligne

Comment trouve-tu le nouvel habillage de l'aldweb Site ?
Superbe !
forum.gifForum - iziBasic - Sujet n°1650

Forum - Forum
iziBasic - iziBasic

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 257

actif  Sujet n° 1650  Random access of database files

le 01/09/2009 @ 01:51
par Roman


The kind of animation found in the Neko Cat example only works if the background is a solid color. In light of this, I've decided to try to store pixel colors in an array so I can restore them after I draw a bitmap over them. Naturally, this requires hundreds of numbers to be stored first.

So, to get to the point, I am having trouble reading these numbers in out of a database. Here's my sample code:

PRINT #1, 17
INPUT #1, A$
KILL "pix"

This is trying to get 17 written in the database, copied to an array, and read out on the screen. I believe the INPUT function is the one I'm having trouble with. Filez shows the "pix" database gains a record (17), but all that is displayed is 0, or "", depending on whether the variable is A or A$.

Perhaps I've said too much :D
  Poster une réponse  Haut

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Réponse n° 1
le 01/09/2009 @ 15:42
par Roman


Well, the amateur has solved his own problem. The reason that A$ was only returning zero or nothing was because the record was blank... the last record that is, the one that A$ was being assigned to. To fix the problem, I amended it to the following:

PRINT #1, 17
SEEK #1, 1 'go to 1st record
INPUT #1, A$ 'read current record

Before, I was reading a blank, end of file record. That's all, folks.
  Poster une réponse  Haut

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Réponse n° 2
le 01/09/2009 @ 21:57
par aldweb


Hello Roman,

I am not sure that your way of proceeding will be the most efficient one in terms of speed.
Have you considered adding a background image, eventually by small squares, so that you would only redraw before drawing back your image on top of the background?
Or you might also use the SAVESCREEN and RESTORESCREEN statements?

Ecrire à aldweb   Poster une réponse  Haut

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Réponse n° 3
le 01/09/2009 @ 22:06
par Roman


As it turns out, that is the route I'm going to need to take. I do like the idea of being able to transform the image's color though.
  Poster une réponse  Haut
actif sujet actif   clos sujet clos   Important! Important!   Nouveau Nouveau message   -   Rectifier Rectifier message   Clôturer Clôturer sujet   Remonter Remonter
Catégories de discussion  Forum 

^ Haut ^