Next question....
I got the initial work done so at least it doesnt blow up on me using:
DataLayer.DataSources.Add(New AS400DataSourceItem("", "Provider=IBMDA400; Data Source=192.168.42.xxx; User ID=xxx; Password=xxx;"))
I didnt actually change much in the custom datasource item, I figured once I mapped it I could debug.
My problem is this, I dont seem to be able to use the BO Mapper. I have the project set to use the OLE DB connection string and it connects, but the mapper only shows SQL Server, then the IP address of the server in the treeview when I hit "Specify Data Source", no tables. The AS400 uses libraries, then files instead of databases and tables, this may be the issue.
This is the code that works not using Strataframe if that helps any. It is just a simple "proof of concept" that loads a single field into a grid.
Being able to use Strataframe with our AS400 client base is huge for us, I appreciate the ongoing help.
Try
Dim sqlstring As String
sqlstring = "SELECT CSANCS FROM FRUITF.PLT"
'setup our connection to the database
Dim oConn As OleDb.OleDbConnection
oConn = New OleDb.OleDbConnection("Provider=IBMDA400; Data Source=192.168.42.xxx; User ID=xxx; Password=xxx;")
oConn.Open()
'setup the data adapter
Dim myDataAdapter As OleDb.OleDbDataAdapter
myDataAdapter = New OleDb.OleDbDataAdapter()
myDataAdapter.SelectCommand = New OleDb.OleDbCommand(sqlstring, oConn)
Dim myData As DataSet
myData = New DataSet()
myDataAdapter.Fill(myData, "PLT")
Dim dt As DataTable
dt = myData.Tables("PLT")
Me.BindingSource1.DataSource = dt
''binding the table to datagrid
Me.DataGridView1.DataSource = Me.BindingSource1
Me.DataGridView1.AutoResizeColumns(DataGridViewAutoSizeColumnsMode.AllCellsExceptHeader)
Me.DataGridView1.Refresh()
'close the connection
oConn.Close()
Catch ex As Exception
MsgBox(ex.ToString)
End Try
Keith Chisarik