bonjour thau thème,
j'ai un fichier, seulement il y a des informations sensibles dessus qui concernent nos collaborateurs...
Je ne veux pas que l'on me marche le travail mais seulement que l'on me donne des pistes concernant la marche à suivre...
voilà où j'en suis:
Private Sub cbncréer_click()
'création d'une session
Sheets("BDD FORM").Select
If cbxnom = "" Then
MsgBox "Veuillez renseigner le champs 'Nom'."
Else
If MsgBox("Confirmez-vous l'ajout des données?", vbYesNo, "Confirmation") = vbYes Then
Sheets("BDD FORM").Select
'renvoyer au bouton ajouter
If MsgBox("Souhaitez-vous ajouter un autre stagiaire?", vbYesNo, "Confirmation") = vbYes Then
'Ajouter un stagiaire à la formation
Sheets("BDD FORM").Select
' effacer les données du collab précédent
cbxnom = ""
Cbxprenom = ""
txtCsp = ""
Txtsex = ""
txtAge = ""
txtdateentree = ""
txtService = ""
Else
'remplir l'identité du nouveau stagiaire
LIGNE = Sheets("BDD FORM").Range("B456541").End(xlUp).Row + 1
Cells(LIGNE, 2) = cbxnom.Value
Cells(LIGNE, 3) = Cbxprenom.Value
Cells(LIGNE, 4) = txtService.Value
Cells(LIGNE, 5) = txtAge.Value
Cells(LIGNE, 6) = txtdateentree.Value
Cells(LIGNE, 7) = txtCsp.Value
Cells(LIGNE, 8) = Txtsex.Value
'copier-coller les données de la partie formation
Dim ligVide As Long
ligVide = Sheets("BDD FORM").Range("B" & Rows.Count).End(xlUp).Row + 1
With Worksheets("BDD FORM")
derlig = .Range("B" & Rows.Count).End(xlUp).Row
.Cells(derlig, 9) = txtPdc.Value
LIGNE = Sheets("BDD FORM").Range("B456541").End(xlUp).Row + 1
Cells(LIGNE, 2) = cbxnom.Value
Cells(LIGNE, 3) = Cbxprenom.Value
Cells(LIGNE, 4) = txtService.Value
Cells(LIGNE, 5) = txtAge.Value
Cells(LIGNE, 6) = txtdateentree.Value
Cells(LIGNE, 7) = txtCsp.Value
Cells(LIGNE, 8) = Txtsex.Value
Cells(LIGNE, 9) = txtPdc.Value
Cells(LIGNE, 10) = cbxCategorie.Value
Cells(LIGNE, 11) = cbxType.Value
Cells(LIGNE, 12) = cbxTheme.Value
Cells(LIGNE, 13) = cbxIntitule.Value
Cells(LIGNE, 14) = CbxOrganisme.Value
Cells(LIGNE, 15) = txtDatedeb.Value
Cells(LIGNE, 16) = TxtDatefin.Value
Cells(LIGNE, 17) = Txtduree.Value
Cells(LIGNE, 18) = CbxEtat.Value
Cells(LIGNE, 19) = txtCoutsal.Value
Cells(LIGNE, 20) = txtCoutpeda.Value
Cells(LIGNE, 21) = cbxFrais.Value
Cells(LIGNE, 22) = txtOpco.Value
End With
End If
End If
End If
End Sub
Comme je l'ai dit je suis novice alors excusez mon manque de clareté !!