Ive had a quick search around, Im sure this must have cropped up before, but couldnt find anything.
I hope I can explain what I'm after, sorry if the words I use arent correct, I never know the 'proper' techy terms for things.
I am trying to return the Pointer to a Type.
Not an individual Field of a particular Type instance, but a means of identifying the instance itself without having to check for matching fields. (Because that has already been done)
As an example, consider:
This simple Type would be populated with:
All good so far, right?
Now, because of the amount of times where I need to iterate through the Type to find the instance I want, I want to put in a function like:
The above gives an "Illegal Type conversion" error at the line:
Unsuprisingly because I just used that as an example, but as for what to actually substitute in is what I'm stuck on!
Is there any way to return the Instance itself from a function?
I hope I can explain what I'm after, sorry if the words I use arent correct, I never know the 'proper' techy terms for things.
I am trying to return the Pointer to a Type.
Not an individual Field of a particular Type instance, but a means of identifying the instance itself without having to check for matching fields. (Because that has already been done)
As an example, consider:
Type Movies Field Title$ Field Runtime End Type
This simple Type would be populated with:
"Star Wars",110 "Conan The Barbarian",90 "Big Trouble In Little China",87
All good so far, right?
Now, because of the amount of times where I need to iterate through the Type to find the instance I want, I want to put in a function like:
Function GetMovie(Title$) For IterateMovies.Movies=Each Movies If Iter\Title$=Title$ Return IterateMovies Exit End If Next Return Null End Function
The above gives an "Illegal Type conversion" error at the line:
Return IterateMovies
Unsuprisingly because I just used that as an example, but as for what to actually substitute in is what I'm stuck on!
Is there any way to return the Instance itself from a function?