Hi everyone,

I used the following format of code to access database, can anyone tell me how to duplicate a record :


Code:
    Dim CN As ADODB.Connection
    Dim RS As ADODB.Recordset
    
    Set CN = CreateObject("ADODB.Connection")
    Set RS = CreateObject("ADODB.Recordset")
    
    CN.Open "dbclient"
    RS.Open "select * from clientstyle where clientstyleclient='" & strClientCode & "' and clientstylestyle='" & strStyleCode & "'", CN, adOpenDynamic, adLockPessimistic
    
    If RS.EOF Then

    End If

    RS.Close
    CN.Close

    Set RS = Nothing
    Set CN = Nothing
Thank You In Advance