Home All Groups Group Topic Archive Search About
Author
19 Oct 2005 9:17 PM
Arpan
When I run the following in the Immediate Window

Format(Sin(1 * 3.14159265358979 / 180), "0.################")

the output is 0.0174524064372835 but when the actual Form is run, the
output of the above Format function is 1.74524064372835E-02! Why so &
how do I ensure that when the Form is run, the output is not in the
exponential form?

Thanks,

Arpan

Author
19 Oct 2005 9:21 PM
Arpan
PLEASE NEGLECT THIS POST & SORRY FOR THE SAME!

Thanks,

Regards,

Arpan
Author
19 Oct 2005 10:14 PM
MikeD
"Arpan" <arpan***@hotmail.com> wrote in message
news:1129756903.814921.59980@g44g2000cwa.googlegroups.com...
> PLEASE NEGLECT THIS POST & SORRY FOR THE SAME!
>


OK. That's a few times in the past few days or so you've posted a question
and then just minutes later posted again saying to ignore it.  I don't have
much of a problem with that in itself.  It's good that you're solving things
on your own. BUT....maybe spend some time trying to solve it BEFORE you
post? And when you do solve it on your own and post an "ignore" message,
provide some information about how you solved it. THAT'S the problem that I
have with your "ignore" posts. Somebody else might read your post and have
the exact same problem. But you don't tell how you corrected it.

--
Mike
Microsoft MVP Visual Basic
Author
19 Oct 2005 9:25 PM
Rick Rothstein [MVP - Visual Basic]
> When I run the following in the Immediate Window
>
> Format(Sin(1 * 3.14159265358979 / 180), "0.################")
>
> the output is 0.0174524064372835 but when the actual Form is
run, the
> output of the above Format function is 1.74524064372835E-02! Why
so &
> how do I ensure that when the Form is run, the output is not in
the
> exponential form?

I think you need to tell us more about how you are handling this
in your form's code. When I Debug.Print that expression in the
Form Load event, it prints out the same value as it does in the
Immediate window. Now, if you are assigning the output from the
above expression to a numeric variable, then all bets are off as
to formatting. String variables can hold formatted numbers,
numerical variables can't (a number is a number... it has no
format). If my last two sentences don't address your problem, we
will need to see some code to see what it is you are actually
doing.

Rick