Torna al Thread

Public Class AdapterClienti Implements MyCommon.IClienti '... ecc... Public Function GetClienti() As List(Of MyCommon.ICliente) Implements MyCommon.IClienti.GetClienti 'Popola la tabella Me.Adapter.SelectCommand = Me.SelectCommand <--- Ho una proprietà privata che mi gestisce il Command Dim Table As ClientiDB = New ClientiDB Me.Adapter.Fill(Table) 'Crea variabile per valore di ritorno Dim ret As New List(Of MyCommon.ICliente) 'Itera sulla tabella per creare valore di ritorno For Each r As MyCommon.ICliente In Table.Rows ret.Add(CType(r, MyCommon.ICliente)) Next Return ret End Function '... ecc... End Class
Copyright © dotNetHell.it 2002-2024
Running on Windows Server 2008 R2 Standard, SQL Server 2012 & ASP.NET 3.5