Home All Groups Group Topic Archive Search About
Author
2 Feb 2006 2:39 PM
S Shulman
Hi
Is there a ny function in VB that returns a minus figure? Receives 150 and
returns -150

Thank you,

Shmuel

Author
2 Feb 2006 2:44 PM
Patrice
i=-i ?

--
Patrice

Show quoteHide quote
"S Shulman" <smshul***@hotmail.com> a écrit dans le message de
news:eU5WyZAKGHA.964@tk2msftngp13.phx.gbl...
> Hi
> Is there a ny function in VB that returns a minus figure? Receives 150 and
> returns -150
>
> Thank you,
>
> Shmuel
>
>
Author
2 Feb 2006 2:52 PM
Herfried K. Wagner [MVP]
"S Shulman" <smshul***@hotmail.com> schrieb:
> Is there a ny function in VB that returns a minus figure? Receives 150 and
> returns -150

'x = -x'.

--
M S   Herfried K. Wagner
M V P  <URL:http://dotnet.mvps.org/>
V B   <URL:http://classicvb.org/petition/>
Author
2 Feb 2006 5:16 PM
Chris
S Shulman wrote:
> Hi
> Is there a ny function in VB that returns a minus figure? Receives 150 and
> returns -150
>
> Thank you,
>
> Shmuel
>
>

X = X * -1
Author
3 Feb 2006 8:06 AM
Hal Rosser
"S Shulman" <smshul***@hotmail.com> wrote in message
news:eU5WyZAKGHA.964@tk2msftngp13.phx.gbl...
> Hi
> Is there a ny function in VB that returns a minus figure? Receives 150 and
> returns -150
>
> Thank you,
>
> Shmuel

Not a function - an operator. Put a minus sign in front of the number. (OR
multiply it by minus one)