Quantcast
Channel: VBForums - Visual Basic 6 and Earlier
Viewing all articles
Browse latest Browse all 21096

String formula to Double

$
0
0
Hi guys!

Let's say I have this:
Code:

Private Sub Command1_Click()
Dim a As String
Dim b(2) As Double
b(0) = Me.Text1.Text
b(1) = Me.Text2.Text
a = "b(0) + b(1)"
b(2) = a
Me.Text3.Text = b(2)
End Sub

It gives error , ofcourse, in the bold line. How to overcome this? I know, removing the quotes will ease all the pain but assume that once I built the formula like this and trying to make Double accept the formula.

Thanks a lot!

Viewing all articles
Browse latest Browse all 21096

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>