Advertisement
jsbsan

CheckBoxRadioButton

Apr 7th, 2014
3,097
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
GAMBAS 1.46 KB | None | 0 0
  1. Public Sub Form_Open()
  2.   ''NOTE: Valores iniciales
  3.  
  4.   RadioButtonCPUI3.value = True
  5.   RadioButtonMemoria1GB.value = True
  6.   RadioButtonMetalico.Value = True
  7.  
  8. End
  9.  
  10. Public Sub ButtonPedido_Click()
  11.  
  12.   TextLabelPedido.text = "Se van a comprar un total de " & Str$(SpinBoxCantidad.Value) & " unidades de ordenadores<br>"
  13.  
  14.   If CheckBoxCPU.Value = False Then
  15.     TextLabelPedido.text &= "Sin CPU <br>"
  16.   Else
  17.     If RadioButtonCPUI3.value = True Then TextLabelPedido.text &= "CPU serán I3<br>"  
  18.     If RadioButtonCPUI5.value = True Then TextLabelPedido.text &= "CPU serán I5<br>"  
  19.     If RadioButtonCPUI7.value = True Then TextLabelPedido.text &= "CPU serán I7<br>"  
  20.   Endif
  21.  
  22.   If CheckBoxMemoria.value = False Then
  23.     TextLabelPedido.text &= "Sin memoria <br>"
  24.   Else
  25.     If RadioButtonMemoria1GB.value = True Then TextLabelPedido.text &= "Memoria Ram de 1 GB<br>"  
  26.     If RadioButtonMemoria2GB.value = True Then TextLabelPedido.text &= "Memoria Ram de 2 GB <br>"  
  27.     If RadioButtonMemoria4GB.value = True Then TextLabelPedido.text &= "Memoria Ram de 4 GB<br>"  
  28.     If RadioButtonMemoria8GB.value = True Then TextLabelPedido.text &= "Memoria Ram de 8 GB<br>"  
  29.   Endif
  30.  
  31.   If RadioButtonMetalico.Value = True Then
  32.     TextLabelPedido.text &= "Forma de pago: Metalico"
  33.   Else
  34.     'como solo hay dos formas de pago, en caso que no sea en metalico será con tarjeta
  35.     TextLabelPedido.text &= "Forma de pago: Tarjeta"
  36.    
  37.   Endif
  38.  
  39. End
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement