Case "select"
Dim result As DBResult = reqManager.HandleJob(job)
For Each records() As Object In result.Rows
Dim a1,a2,a3,a4,a5,a6,a7 As String
Dim buffer() As Byte
buffer = records(result.Columns.Get("imagen"))
a1 = records(result.Columns.Get("lote"))
a2= records(result.Columns.Get("nombre"))
a3 = records(result.Columns.Get("gramaje"))
a4 = records(result.Columns.Get("precio"))
a5 = records(result.Columns.Get("leche"))
a6 = records(result.Columns.Get("azucar"))
a7 = records(result.Columns.Get("instantaneo"))
p.Initialize("")
p2.Initialize("")
Activity.AddView(p,0,0,100%y,100%x)
p.LoadLayout("2")
p.RemoveView
img.Bitmap = reqManager.BytesToImage(buffer)
Label1.Text = a1
label2.Text = a2
label3.Text = a3&"Gr"
label4.Text = a4
convert = a4
convert = NumberFormat2(a4,0,2,2,True)
Label12.Text = convert
If a5 = 1 Then
ck1.Bitmap = bitmap7
Else
ck1.Bitmap = bitmap8
End If
'
If a6 = 1 Then
ck2.Bitmap = bitmap7
Else
ck2.Bitmap = bitmap8
End If
'
If a7 = 1 Then
ck3.Bitmap = bitmap7
Else
ck3.Bitmap = bitmap8
End If
If vartomada < a4 Then
label5.Text = a4-vartomada
label5.Text = NumberFormat2(label5.Text,0,2,2,True)
End If
If vartomada < a4 Then
ImageView2.Bitmap = bitmap4
End If
If vartomada > a4 Then
label5.Text = vartomada-a4
label5.Text = NumberFormat2(label5.Text,0,2,2,True)
End If
If vartomada > a4 Then
ImageView2.Bitmap = bitmap5
End If
clv1.Add(p,p.Height,"")
Next
End Select