View Single Post
Old January 23rd, 2004, 04:48 PM
tomz tomz is offline
Registered User
Join Date: Jan 2004
Location: , , .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default vb6 to conversion question

I have a vb6 appl that I am converting to I am having trouble replacing/converting vb6 use of the LSet stmt (LSet is not supported in Does anyone have any ideas?

The vb6 code uses the following public types:
Public Type SecurityAccessProps
    strUserName As String * 30
    strApplID As String * 30
    strApplType As String * 1
    strApplDesc As String * 50
    lngAccessLevel As Long
    dtDateLastUpdated As Date
    strLastUpdatedBy As String * 30
    dtDateCreated As Date
    strCreatedBy As String * 30
    blnIsNew As Boolean
    blnIsDeleted As Boolean
    blnIsDirty As Boolean
End Type

Public Type SecurityAccessBuffer
    strBuffer As String * 186
End Type
__________________________________________________ ___

The vb6 code is as follows:

Private mudtProps As SecurityAccessProps

Private Sub SetState(strBuffer As String)
    Const SUB_NAME = "SetState"
    Dim udtData As SecurityAccessBuffer

    udtData.strBuffer = strBuffer
    LSet mudtProps = udtData
End Sub

Private Function GetState() As String
    Const SUB_NAME = "GetState"
    Dim udtData As SecurityAccessBuffer

    LSet udtData = mudtProps
    GetState = udtData.strBuffer

End Function

Is there a way in vb6 to re-write/replace the LSet stmt so the udtdata string buffer can be assigned the SecurityAccessType data and vice versa for the SetState & GetState functions? I need to keep the String functionality of the SetState & GetState functions.
OR ...
Is there a way to convert this code to without the LSet stmt? Again, I need to keep SetState & GetState as Strings.