Sub GetQuery(Query As String,StrJobName As String)
Dim Job As HttpJob
Job.Initialize(StrJobName, Me)
Job.PostString("http://103.76.188.138:85/Android/FrmGetQuery.aspx?Query="&Query,"")
ProgressDialogShow("Calling KHARIND server...")
End Sub
Sub JobDone (Job As HttpJob)
Try
Msgbox(Job.JobName,"")
Msgbox(Job.GetString(),"")
If Job.Success Then
If (Job.JobName = "StageList") Then
Dim parser As JSONParser
parser.Initialize(Job.GetString())
Dim root As List = parser.NextArray
For Each colroot As Map In root
SpinnerMap.Put(colroot.Get("Stage"), colroot.Get("Serial"))
CboStage.Add(colroot.Get("Stage"))
Next
StrStageCode = CboStage.SelectedItem
Else if (Job.JobName = "CutSlipDet") Then
Dim parser As JSONParser
parser.Initialize(Job.GetString())
Dim root As List = parser.NextArray
For Each colroot As Map In root
TxtOrderNo.Text = colroot.Get("OrderNo")
TxtStyleNo.Text = colroot.Get("Style")
TxtColor.Text = colroot.Get("Color")
TxtPairs.Text = colroot.Get("Pairs")
Next
End If
ProgressDialogHide
Else
Msgbox("Failed","")
ProgressDialogHide
End If
Job.Release
Catch
Msgbox(LastException,"")
ProgressDialogHide
End Try
End Sub
Sub CmdPrev_Click
'CboStage.SelectedIndex = CboStage.SelectedIndex - 1
GetQuery("Select C.*,L.itemdesc Leather,Li.itemdesc Lining,P.cuttype,P.cutbtc,P.sewtype,P.finbtc FinBTL,P.Image,S.PDesc Hemming from Arind.Dbo.FnCutSlipMovesNew('" & TxtCutSlipNo.Text & "','" & StrStageCode & "') C Join Arind.Dbo.ProSpec P On P.StyleNo = C.Style Join Arind.Dbo.Leather L On L.itemcode = SubString(P.Leather1,1,6) Left Join Arind.Dbo.Lining Li On Li.itemcode = P.lining Left Join Arind.Dbo.SpecParam S On S.pcode = P.hemtype And S.ptype = 'HM'","CutSlipDet")
End Sub