CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2

Thread: If then else

  1. #1
    Join Date
    Oct 2001
    Location
    CA
    Posts
    16

    If then else


    HELP! Anyone
    I have the below Menu GUI created but I'm not so sure as to where to start on the vbcode.
    Do I use an if then else example....
    My Menu looks like this:

    File
    Pay ;ie Menu button
    Summary;ie Menu buton
    Vb GUI looks like this:
    Sales Amount [ ]
    Total Pay [ ]
    Commission [ ]
    If the Sales amount is about a certain quota;ie 500 then the sales person will not get a commission of (15%) commission + his base pay of 100.
    The (15%)com + his base pay should equal his total pay to be displayed on the above GUI. If quota is not met then only the basepay will be displayed.
    Thanks!

    Juan Amore

  2. #2
    Join Date
    Feb 2001
    Posts
    54

    Re: If then else

    Sales Amount [ ]
    Total Pay [ ]
    Commission [ ]
    If the Sales amount is about a certain quota;ie 500 then the sales person will not get a commission of (15%) commission + his base pay of 100.
    The (15%)com + his base pay should equal his total pay to be displayed on the above GUI. If quota is not met then only the basepay will be displayed.
    Thanks!




    'text1.text is sales
    dim base_pay as single
    dim Total_pay as single
    base_pay=23000
    If sales>=501 then
    Total_pay=(val(Text1.text)*.15) + base_pay
    else
    Total_pay=base_pay
    end if




    Good Luck


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured