validacion en manifiesto venta agrojam

This commit is contained in:
JORGE LUIS CAUDILLO ESPARZA
2024-12-02 03:33:21 -07:00
parent bfb713d3d0
commit 437f5b8894

View File

@@ -298,7 +298,19 @@ Public Class ClsNominas
SqlAdapter.Fill(DTSet)
If DTSet.Tables.Count > 0 Then
Data = DTSet.Tables(0)
If DTSet.Tables.Count > 1 AndAlso DTSet.Tables(1).Rows.Count > 0 Then
Dim errormsg As String = "Se han detectado cultivos ("
Dim coma As String = ""
For Each row As DataRow In DTSet.Tables(1).Rows
errormsg = String.Format("{0}{1} {2}", errormsg, coma, row("Cultivo"))
coma = ","
Next
errormsg = String.Format("{0} ) que no tienen un producto vinculado. Por favor, revise el catálogo de cultivos para completar la información.", errormsg)
Alert(errormsg, TipoMensaje.MsgAdvertencia)
End If
End If
retorno = True
Catch Ex1 As SqlException