Results 1 to 4 of 4

Thread: Basic BASIC problem :p

  1. #1

    Thread Starter
    Frenzied Member
    Join Date
    Jun 2001
    Location
    USA
    Posts
    1,026

    Talking Basic BASIC problem :p

    I have this in one of my basic programs...

    Data 0,0,0,0,0
    Data 1,4,5,3,1
    Data 1,4,7,9,3

    What I need is to be able to put those values into a file and import them when I need them....

    How can I do that?

    Thanks
    Now happily married and still crankin' away at the keyboard. Life is grand for a coder, no?

  2. #2
    Member
    Join Date
    Jul 2003
    Location
    UK
    Posts
    60
    I would be inclined to print them to a file separated with a comma for easy separation when it comes to reading them back again.

    NIck

  3. #3
    Lively Member meander's Avatar
    Join Date
    Jun 2004
    Posts
    121
    do you need to know how to export things to a file or do you know what nickjc is talkin about?
    I'm having a problem here. Do I put the serial number in the box that says 'serial number,' or do I put it in the box that says 'company'? - Oh, those poor tech support people

    Jiveman: Lookie here, I can dig grease and butter on some draggin' fruit garden.

  4. #4
    Lively Member meander's Avatar
    Join Date
    Jun 2004
    Posts
    121
    heres a quick program i threw together to just print those data values to a file...


    Code:
    OPEN "c:\data.dat" FOR OUTPUT AS #1
    
    1 : READ val1, val2, val3, val4, val5
    IF val1 <> -99 THEN
      WRITE #1, val1, val2, val3, val4, val5
    ELSE
      END
    END IF
    GOTO 1
    
    DATA 0,0,0,0,0
    DATA 1,4,5,3,1
    DATA 1,4,7,9,3
    DATA -99,-99,-99,-99,-99
    i dont know if it helps you any though...
    I'm having a problem here. Do I put the serial number in the box that says 'serial number,' or do I put it in the box that says 'company'? - Oh, those poor tech support people

    Jiveman: Lookie here, I can dig grease and butter on some draggin' fruit garden.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width