How do I know what type is returned from a command

BlitzMax Forums/MaxGUI Module/How do I know what type is returned from a command

Farflame(Posted 2010) [#1]
Sorry if that headline is a big vague, but my question is, how do I know if a command is going to return an int, a long, a string etc? I need to know because I'm using Superstrict.

The command I'm using at the moment is Confirm. The manual says - Function Confirm( text$,serious=False ).

I was trying Local Result:Int=Confirm("Are you sure?") but I get the error 'Unable to convert from Int(String,Int) to Int'.

So if someone could let me know which type I need here, and also, how I can work it out for myself for other commands? Thanks :)


Wiebo(Posted 2010) [#2]
Your code is just fine. Confirm() returns true or false (0 or 1). Something else must be wrong somewhere else. Are you using Framework and did you forget to add a module?


Farflame(Posted 2010) [#3]
Doh, silly mistake, I forgot to put the brackets around the "Are you Sure?" xD