Para cerrar puedes usar
Private Sub Cerrar_Click()
Unload me 'Tomando en cuenta que estas en el mismo formulario
End Sub
Respecto a verificar si has escrito y que aparezca un mensaje sobre guardar cambios o cancelar.
'Yo lo haria de la siguiente manera
'para verificar si escriben o no en unos de los textbox
Function CompruebaCampos()
Dim Texto1 As String
Texto1 = "Por favor Guarde los Cambios"
If Len(txtCodigo) <> TextoCodigoFlex Then
MsgBox Texto1, vbExclamation, Me.Caption
Exit Function
End If
If Len(txtcedula) <> TextoCedulaFlex Then
MsgBox Texto1, vbExclamation, Me.Caption
Exit Function
End If
If Len(txtNombres) <> TextoNombresFlex Then
MsgBox Texto1, vbExclamation, Me.Caption
Exit Function
End If
If Len(txtApellidos) <> TextoApellidosFlex Then
MsgBox Texto1, vbExclamation, Me.Caption
Exit Function
End If
End Function