Text?

Posts 1–6 of 6 · Page 1 of 1
Text?
Hello,

I've used ZeaS module maker for VB6, now I want to retrieve a TEXT, not a LONG or something. Anyone have any ideas? I tried this, didn't work:

Code:
    Call ReadAByte(Command, &HA2B20E, Bytes)
    For I = LBound(Bytes) To UBound(Bytes)
        strMapname = strMapname & CStr(Bytes(I))
    Next
Any ideas?

Thanks.
FIXED!

Here are the functions I've made to do it:
Code:
Dim sByte As Byte

Function ReadAString(Addie As Long, Optional Lenght As Long = 255) As String
    Dim Temp As String
    Dim I As Integer
    For I = 0 To Lenght
        Call ReadAByte(Command, Addie + I, sByte)
        Temp = Temp & Chr(sByte)
    Next
    Temp = nullTrim(Temp)
    ReadAString = Temp
End Function

Function nullTrim(s As String) As String
    Dim n As Integer
    n = InStr(s, Chr$(0))
    If (n > 0) Then
        nullTrim = Trim(Left(s, n - 1))
    Else
        nullTrim = Trim(s)
    End If
End Function
All my code.
Did I help anyone with this piece of code?
need help understanding this post i need to write a string but this isn't makeing sense? someone explain plz?
lol figured out this if anyone needs help reading a string just pm me : )


Quote Originally Posted by SomeDude123 View Post
sorry, dunno how
Posts 1–6 of 6 · Page 1 of 1
This thread is closed for replies.

Similar Threads

Tags for this Thread

Need help?