0

ok, so in Java you do "blahblah " + variable + " blahblah"
which outputs into "blahblah 23 blahblah"

but how do I do this in VB? I wanted to have a label with

HPvariable + "/" + MAXHPvariable

so it'll display 18/23 etc...

3
Contributors
3
Replies
4
Views
7 Years
Discussion Span
Last Post by vb5prgrmr
0

create a form
place one label & command button
code for command button

'----------------------------------
Private Sub Command1_Click()
Dim v1, v2 As Long
v1 = 100
v2 = 200
Label1.Caption = Trim(CStr(v1)) & "/" & Trim(CStr(v2))
End Sub


reply

0

BTW santosh5471 and pasido, in santosh's example only the V2 variable is declared as long while the V1 variable is a varient... Just so you know...

Good Luck

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.