I need to create a couple of functions in VB. One to return the log(10) of a number and one to do the reverse, convert the ani-log back again.
If anyone can help would be much appreciated.
Thanks.
Printable View
I need to create a couple of functions in VB. One to return the log(10) of a number and one to do the reverse, convert the ani-log back again.
If anyone can help would be much appreciated.
Thanks.
ok, here's how to calculate log10 from natural log
Log10 = Log(value) / Log(10)
the opposite way around:
10^value
Damn beat me! :p :D
VB Code:
Private Sub Command1_Click() x = 100000 Label1 = Log(x) / Log(10) y = Val(Label1.Caption) Label2 = 10 ^ y End Sub
Thanks to all.
Regards,
replace log(10) with 2.30258509299405
since that's a totally unnessesary computation