google.com, pub-4617457846989927, DIRECT, f08c47fec0942fa0 Learn to enjoy every minute of your life.Only I can change my life.: Write a Visual Basic Program to make customer Survey and with their name and then display the survey result.

Monday, February 23, 2015

Write a Visual Basic Program to make customer Survey and with their name and then display the survey result.

Write a Visual Basic Program to make customer Survey and  with their name and then display the survey result.
------------------------------------------------------------------------------------------
Design Window:-
 First Form :-

Second form:-

Code;-
Dim Excellent As Integer
Dim Satisfactory As Integer
Dim Average As Integer
Dim Bad As Integer
Dim Total As Integer

Private Sub cmdContinue_Click()
If optExcellent.Value Then
    Excellent = Excellent + 1
ElseIf optSatisfactory.Value Then
    Satisfactory = Satisfactory + 1
ElseIf optAverage.Value Then
    Average = Average + 1
Else
    Bad = Bad + 1
End If
txtName.Text = ""
optExcellent.Value = False
optSatisfactory.Value = False
optAverage.Value = False
optBad.Value = False
txtName.SetFocus
End Sub

Private Sub cmdQuit_Click()
Total = Excellent + Satisfactory + Average + Bad
With frmServeyResult
    .lblExcellent = Excellent
    .lblSatisfactory = Satisfactory
    .lblAverage = Average
    .lblBad = Bad
    .lblExcellentPer = Format((Excellent / Total) * 100, "#0.00")
    .lblSatisfactoryPer = Format((Satisfactory / Total) * 100, "#0.00")
    .lblAveragePer = Format((Average / Total) * 100, "#0.00")
    .lblBadPer = Format((Bad / Total) * 100, "#0.00")
End With
frmServeyResult.Show
Unload Me
End Sub

========================================
OUTPUT
After entry of six customers response of first form survey result is:-



हिम्मत

 अंधेरे में एक करोड का हीरा गिर गया था, उसे ढूंढने के लिए पाँच रूपएं की मोमबत्ती ने सहयोग किया। अभी बताओ वह पाँच रूपएं की एक छोटी सी मोमबत्त...