[Gambas-user] Val()

Tim Dickson dickson.tim at googlemail.com
Thu May 27 12:29:38 CEST 2021


good old two's compliment.
Unless the int is unsigned, you don't normally have negative hex, so it 
probably expects it to be a signed short int/int

On 27/05/2021 08:12, Bruce wrote:
> On 27/5/21 4:26 pm, Bruce Steers wrote:
>> On Thu, 27 May 2021 at 07:55, Bruce Steers <bsteers4 at gmail.com> wrote:
>>
>>>
>>>
>>> On Thu, 27 May 2021 at 07:40, CD <claude.dessere at orange.fr> wrote:
>>>
>>>> Hello,
>>>>
>>>> why Val("&FFFF") = -1
>>>> and
>>>> why Val("&FFFFFFFF") = -1
>>>>
>>>> is it normal?
>>>>
>>>>
>>> I is when you do it wrong
>
>
> or perhaps, maybe, could it possibly be just because one is a short 
> and one is a long.  So their both -1
>  ;-)
>
>
>>> you must put & at begining and end...
>>>
>>> Try this...
>>> Val("&FFFF&)
>>>
>>> oops  no quote..
>> Val("&FFFF&")
>>
>> BruceS
>>
>>
>
>
>
> ----[ http://gambaswiki.org/wiki/doc/netiquette ]----


-- 
This email has been checked for viruses by AVG.
https://www.avg.com



More information about the User mailing list