REALIZAR ESTA FACTURA SENCILLA SI LA COMPRA ES >=100 APLICAR EL 5% DE DESCUENTO, SE CALCULA %5 =0.05 EL TOTAL A PAGAR SE RESTA TOTAL -DESCUENTO SI NO HAY DESCUENTO EL ES CERO Y EL TOTAL SERA IGUAL AL TOTAL A PAGAR
Private Sub CommandButton1_Click() TextBox5.Text = Val(TextBox3.Text) * Val(TextBox4.Text) If Val(TextBox5.Text) >= 4000 Then TextBox6.Text = Val(TextBox5.Text) * 0.02 Else TextBox6.Text = 0 End If TextBox7.Text = Val(TextBox5.Text) - Val(TextBox6.Text) End Sub _________________________________________________________________________________ IF ANIDADO Private Sub CommandButton1_Click() If Val(TextBox1.Text) = 1 Then TextBox2.Text = " HOY ES DIA LUNES" Else If Val(TextBox1.Text) = 2 Then TextBox2.Text = " HOY ES DIA MARTES" Else If Val(TextBox1.Text) = 3 Then TextBox2.Text = " HOY DIA MIRCOLES" Else If Val(TextBox1.Text) = 4 Then TextBox2.Text = " HOY DIA JUEVES" Else If Val(TextBox1.Text) = 5 Then TextBox2.Text = " HOY DIA VIERNES" Else If Val(TextBox1.Text) = 6 Then TextBox2.Text = " HOY DIA SABADO" Else If Val(TextBox1.Text) = 7 Then TextBox2.Text = " DOMINGO"...