K
kosherpiggy
I want to increment a byte when I have Option Strict on and I don't
want to do any casting. The code below does it but it is hard on the
eyes.
Dim lineNumber As Byte = 0
Dim incrementer As Byte = 1
For Each line As Line In mCollection
lineNumber += incrementer
line.LineNumber.Value = lineNumber
Next
I'd like to do something more like this
Dim lineNumber As Byte = 0
For Each line As Line In mCollection
lineNumber += 1y
line.LineNumber.Value = lineNumber
Next
Where y is what ever suffix would create that nameless temporary object
as a byte with the value of 1.
Is there a way to do this? Is there a better way to increment a byte?
Thanks,
Russ
want to do any casting. The code below does it but it is hard on the
eyes.
Dim lineNumber As Byte = 0
Dim incrementer As Byte = 1
For Each line As Line In mCollection
lineNumber += incrementer
line.LineNumber.Value = lineNumber
Next
I'd like to do something more like this
Dim lineNumber As Byte = 0
For Each line As Line In mCollection
lineNumber += 1y
line.LineNumber.Value = lineNumber
Next
Where y is what ever suffix would create that nameless temporary object
as a byte with the value of 1.
Is there a way to do this? Is there a better way to increment a byte?
Thanks,
Russ