Necesito convertir de unidad a pack.
1 Pack = 12 unidades.
Private Sub Command1_Click()
Dim xEntero As Integer
Dim xUnidad As Integer
xEntero = Format(Val(Text1.Text) / 12, "")
xUnidad = Format(Val(Text1.Text), "") - xEntero * 12
If xUnidad > 0 Then
Debug.Print xEntero & " PACK CON " & xUnidad & " LATAS"
Else
Debug.Print xEntero & " PACK"
End If
End Sub
En algunos casos no me convierte bien, por ejemplo si pongo 69 unidad me tira directo a 6 pack, y deberia de ser 5 pack con 9 latas.