demande d'information

الموضوع في 'أرشيف المنتدى التعليمي' بواسطة channoufa, بتاريخ ‏19 جويلية 2008.

  1. channoufa

    channoufa عضو مميز

    إنضم إلينا في:
    ‏11 جانفي 2007
    المشاركات:
    1.184
    الإعجابات المتلقاة:
    130
      19-07-2008 13:36
    je sui entrain d realisé un ptit prog avc VB mai jé eu dé prob avc
    ds le codage au niveau dé commande de navigation é d modification , ajout ,recherche ...
    j vs donne le code é si kelkun m trouv cé koi l prob ou sa faute repond moi c urgent


    voici l code


    Private Sub cmdajouter_Click()
    DataEnvironment1.rsCommand1.AddNew
    affichage (False)
    End Sub

    Private Sub cmdannuler_Click()
    DataEnvironment1.rsCommand1.CancelUpdate
    affichage (True)
    End Sub

    Private Sub cmdmodifier_Click()
    affichage (False)
    End Sub

    Private Sub cmdNavigation_Click(Index As Integer)
    Select Case Index
    Case 0:
    If DataEnvironment1.rsCommand1.AbsolutePosition = 1 Then
    Beep
    Else
    DataEnvironment1.rsCommand1.MoveFirst
    End If
    Case 1:
    If DataEnvironment1.rsCommand1.AbsolutePosition = DataEnvironment1.rsCommand1.RecordCount Then
    Beep
    Else
    DataEnvironment1.rsCommand1.MoveLast
    End If
    Case 2:
    If DataEnvironment1.rsCommand1.AbsolutePosition = 1 Then
    Beep
    Else
    DataEnvironment1.rsCommand1.MovePrevious
    End If
    Case 3:
    If DataEnvironment1.rsCommand1.AbsolutePosition = DataEnvironment1.rsCommand1.RecordCount Then
    Beep
    Else
    DataEnvironment1.rsCommand1.MoveNext
    End If
    Case 4:
    Unload Me
    End Select

    End Sub

    Private Sub cmdsupprimer_Click()
    DataEnvironment1.rsCommand1.Delete
    DataEnvironment1.rsCommand1.MoveFirst
    affichage (False)
    End Sub

    Private Sub cmdvalider_Click()
    DataEnvironment1.rsCommand1.Update
    affichage (True)
    End Sub

    Private Sub affichage(ByVal b As Boolean)
    cmdNavigation(0).Visible = b
    cmdNavigation(1).Visible = b
    cmdNavigation(2).Visible = b
    cmdNavigation(3).Visible = b
    cmdajouter.Visible = b
    cmdsupprimer.Visible = b
    cmdmodifier.Visible = b
    cmdannuler.Visible = Not b
    cmdvalider.Visible = Not b
    End Sub

    Private Sub Form_Load()
    affichage (True)
    End Sub




    merci d'avance

    @+​
     

مشاركة هذه الصفحة

جاري تحميل الصفحة...