| TIP: Click on subject to list as thread! | ANSI |
| echo: | |
|---|---|
| to: | |
| from: | |
| date: | |
| subject: | how can a math operator be set as a variable? |
Public sValue1 As String, sValue2 As String
Public dValue1 As Double, dValue2 As Double
Public vOper
vOper = "*"
'set operator
variable to "multiply"
sValue1 = txtMain1.Text 'get first string
value
sValue2 = txtMain2.Text 'get second string
value
dValue1 = CDbl(sValue1) 'convert first string
value to double
dValue2 = CDbl(sValue2) 'convert second string
value to double
dResult = (dValue1 & vOper & dValue2)
txtMain2.Text = CStr(dResult)
--- UseNet To RIME Gateway {at} 1/24/05 10:41:16 PM ---
* Origin: MoonDog BBS, Brooklyn,NY, 718 692-2498, 1:278/230 (1:278/230)SEEN-BY: 633/267 270 5030/786 @PATH: 278/230 10/345 106/1 2000 633/267 |
|
| SOURCE: echomail via fidonet.ozzmosis.com | |
Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.