by "Greg Neill" <gneillREM@[EMAIL PROTECTED]
>
Jan 18, 2006 at 01:26 PM
"Alen Hopek" <alen.hopek@[EMAIL PROTECTED]
> wrote in message
news:MPG.1e389d813158113f989680@[EMAIL PROTECTED]
> Hello,
>
> I have a problem with my function here.
> The Function read out a Description from a Norton Ghost Image File.
>
> This works mostly with this Function. The Problem is when i try
> to return the value "Chars" out of my function at the end of the
> Function like:
> ...
> FUNCTION = Chars
> END FUNCTION
>
> then i get an Error:
> Relational operator expected
> Line 230: FUNCTION = Chars
>
> when i try it like this:
> FUNCTION = LEN(Char)
> the function returns a numeric value.
>
> The Return Value of this function should be the Variable "Chars".
>
> Any Idea what went wrong ?
Did you define your function type as STRING when you
tried to return a string?
For example:
FUNCTION MYFUN() as STRING
DIM Z as ASCIIZ*10
Z = "12345"
MYFUN = "AAA" & Z & "BBB"
END FUNCTION
CLS
PRINT ":";MYFUN();":"
END
Will produce:
:AAA12345BBB: