Hi All,
I'm having a problem with this piece of code:
Imports MedfordSchoolDistrict.MobileStaffDevice.DatabaseSpecific
Imports MedfordSchoolDistrict.MobileStaffDevice.EntityClasses
Imports MedfordSchoolDistrict.MobileStaffDevice.FactoryClasses
Imports MedfordSchoolDistrict.MobileStaffDevice.HelperClasses
Imports MedfordSchoolDistrict.MobileStaffDevice.RelationClasses
Imports MedfordSchoolDistrict.MobileStaffDevice.TypedViewClasses
Imports MedfordSchoolDistrict.MobileStaffDevice
Imports SD.LLBLGen.Pro.ORMSupportClasses
Public Class StaffManager
Public Shared Function GetDepartmentEmployees() As VwDepartmentEmployeeNameTypedView
Using adapter As New MobileDataAccessAdapter
Dim vw As New VwDepartmentEmployeeNameTypedView
adapter.FetchTypedView(vw)
Return vw
End Using
End Function
I get the following error when I try to use GetDepartmentEmployess:
System.Data.SqlServerCe.SqlCeException was unhandled
HResult=-2147217865
Message=" [ vwDepartmentEmployeeName ]"
NativeError=0
Source="SQL Server 2005 Everywhere Edition ADO.NET Data Provider"
StackTrace:
at System.Data.SqlServerCe.SqlCeCommand.ProcessResults()
at System.Data.SqlServerCe.SqlCeCommand.CompileQueryPlan()
at System.Data.SqlServerCe.SqlCeCommand.ExecuteCommand()
at System.Data.SqlServerCe.SqlCeCommand.ExecuteReader()
at System.Data.SqlServerCe.SqlCeCommand.ExecuteDbDataReader()
at System.Data.Common.DbCommand.System.Data.IDbCommand.ExecuteReader()
at System.Data.Common.DbDataAdapter.FillInternal()
at System.Data.Common.DbDataAdapter.Fill()
at System.Data.Common.DbDataAdapter.Fill()
at SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.ExecuteMultiRowDataTableRetrievalQuery()
at SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.FetchTypedView()
at SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.FetchTypedView()
at MobileStaffDeviceBl.StaffManager.GetDepartmentEmployees()
at MobileStaffDevice.frmMain.frmMain_Load()
at System.Windows.Forms.Form.OnLoad()
at System.Windows.Forms.Form._SetVisibleNotify()
at System.Windows.Forms.Control.set_Visible()
at System.Windows.Forms.Application.Run()
at MobileStaffDevice.frmMain.Main()
Any help would be appreciated.
Fishy