Author Topic: GET and PUT with TYPE  (Read 2115 times)

0 Members and 1 Guest are viewing this topic.

Offline johannhowitzer

  • Forum Regular
  • Posts: 118
    • View Profile
GET and PUT with TYPE
« on: January 29, 2021, 07:11:13 am »
Had to comment out this line in a file save/load routine:

GET #1, , best_score

best_score is of type score_structure, which has two integers, a _byte, and a string.  Is there a way to use GET and PUT with custom data types?

FellippeHeitor

  • Guest
Re: GET and PUT with TYPE
« Reply #1 on: January 29, 2021, 07:26:44 am »
Make the strings fixed-width in your type, like for example:

TYPE mytype
    element AS STRING * 50
END TYPE

Offline johannhowitzer

  • Forum Regular
  • Posts: 118
    • View Profile
Re: GET and PUT with TYPE
« Reply #2 on: January 29, 2021, 07:28:29 am »
Ah, error message makes way more sense now, thanks.