Invalid Argument Exception


Author
Message
PeterA
PeterA
StrataFrame Novice (74 reputation)StrataFrame Novice (74 reputation)StrataFrame Novice (74 reputation)StrataFrame Novice (74 reputation)StrataFrame Novice (74 reputation)StrataFrame Novice (74 reputation)StrataFrame Novice (74 reputation)StrataFrame Novice (74 reputation)StrataFrame Novice (74 reputation)
Group: Forum Members
Posts: 72, Visits: 235
I'm getting a strange error when I attempt to fill a business object from a DB2 database. I know I must be missing something simple (having just now figured out what I was doing wrong with not being able to even try filling a business object), but I'm just not seeing what the problem is.



First, here's the stack trace:





IBM.Data.DB2.DB2ConnPool.a(String A_0, a& A_1, c& A_2) +11132

IBM.Data.DB2.DB2Connection.set_ConnectionString(String value) +353

MicroFour.StrataFrame.Data.Db2.Db2DataSourceItem.CreateBlankDbConnection() +62

MicroFour.StrataFrame.Data.DbDataSourceItem.GetDataTable(DbCommand Command, OnChangeEventHandler CallBack) +73

MicroFour.StrataFrame.Data.DbDataSourceItem.GetDataTable(QueryInformation QueryInfo, OnChangeEventHandler CallBack) +56

MicroFour.StrataFrame.Data.DataLayer.GetDataTable(QueryInformation QueryInfo, Boolean RegisterNotification) +154

MicroFour.StrataFrame.Business.BusinessLayer.FillDataTable(QueryInformation QueryInfo) +54

Payless.Sourcing.MaterialsManagement.SuppliersListing.Page_Load(Object sender, EventArgs e) in I:\PSS Design\Visual Studio\Materials Management\MM_UI\Suppliers\listing.aspx.cs:54

System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +15

System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +34

System.Web.UI.Control.OnLoad(EventArgs e) +99

System.Web.UI.Control.LoadRecursive() +47

System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1061





What I'm doing is creating a connection which is added to the DataLayer (i.e. mySqlh). I then build a QueryInformation object to get that would fill the business object (i.e. qBizQuery), set the business object's DataSourceKey to the same as the DataSourceKey I just created (from a Web.Config file) and then attempt to fill the business object.





DataLayer.DataSources.Add(new Db2DataSourceItem(Global.Config['DataSourceKey"], connectionString, IBM.Data.DB2.DB2Factory.Instance);



mySqlh = DataLayer.DataSources[Global.Config['DataSourceKey']];



qBizQuery = new QueryInformation();



BizObject.DataSourceKey = Global.Config["DataSourceKey"];

BizObject.FillDataTable(qBizQuery);





The mySqlh object is actually used further down in my code to build a dataset for a gridview control.



So, finally to my question: am I attempting to implement the business objects correctly? Am I missing something else that is causing this invalid argument?



Thanks!
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Threaded View
Threaded View
PeterA - 17 Years Ago
StrataFrame Team - 17 Years Ago
PeterA - 17 Years Ago
StrataFrame Team - 17 Years Ago
PeterA - 17 Years Ago
                         I'm not sure. This is the code from the Db2DataSourceItem for...
StrataFrame Team - 17 Years Ago
                             I did manage to track this down on Friday, but didn't get a chance to...
PeterA - 17 Years Ago
                                 Excellent. I'm glad you got it working because I was stumped :)
StrataFrame Team - 17 Years Ago

Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search