Business Object problem


Author
Message
Pertti Karjalainen
Pertti Karjalainen
StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)
Group: Forum Members
Posts: 54, Visits: 4K
I just refreshed my Strataframe version last night due to various weirdnesses.  Now those weirdnesses are gone, but new weirdnesses are showing up.  Of course, it could be just my own weirness, but nevertheless I need some help...

1. When I go through the Business Object Mapper and set it up as OLDEDB to access my VFP data, everything looks ok until I go to specify the data source.  The system "enumerates" data sources and comes up with this screen:

CPW.DBC is a VFP database, there is no CPW.DBC anywhere in my SQL Server, yet Object Mapper SEEMS to think that this VFP DBC lives in my SQL server.  From here, I can move forward and see the VFP tables and fields just fine.  However, when I run the program and it tries to fill data table, I get this:

And here's the error "dump":

System.ArgumentException was unhandled by user code
  Message="Format of the initialization string does not conform to specification starting at index 0."
  Source="System.Data"
  StackTrace:
       at System.Data.Common.DbConnectionOptions.GetKeyValuePair(String connectionString, Int32 currentPosition, StringBuilder buffer, Boolean useOdbcRules, String& keyname, String& keyvalue)
       at System.Data.Common.DbConnectionOptions.ParseInternal(Hashtable parsetable, String connectionString, Boolean buildChain, Hashtable synonyms, Boolean firstKey)
       at System.Data.Common.DbConnectionOptions..ctor(String connectionString, Hashtable synonyms, Boolean useOdbcRules)
       at System.Data.SqlClient.SqlConnectionString..ctor(String connectionString)
       at System.Data.SqlClient.SqlConnectionFactory.CreateConnectionOptions(String connectionString, DbConnectionOptions previous)
       at System.Data.ProviderBase.DbConnectionFactory.GetConnectionPoolGroup(String connectionString, DbConnectionPoolGroupOptions poolOptions, DbConnectionOptions& userConnectionOptions)
       at System.Data.SqlClient.SqlConnection.ConnectionString_Set(String value)
       at System.Data.SqlClient.SqlConnection.set_ConnectionString(String value)
       at System.Data.SqlClient.SqlConnection..ctor(String connectionString)
       at MicroFour.StrataFrame.Data.SqlDataSourceItem.CreateBlankDbConnection()
       at MicroFour.StrataFrame.Data.DbDataSourceItem.GetDataTable(DbCommand Command, OnChangeEventHandler CallBack)
       at MicroFour.StrataFrame.Data.SqlDataSourceItem.GetDataTable(DbCommand Command, OnChangeEventHandler CallBack)
       at MicroFour.StrataFrame.Data.DbDataSourceItem.GetDataTable(String Statement, OnChangeEventHandler CallBack)
       at MicroFour.StrataFrame.Data.DataLayer.GetDataTable(String Statement, Boolean RegisterNotification)
       at MicroFour.StrataFrame.Business.BusinessLayer.FillDataTable(String SelectStatement)
       at CMBPermitsBOLibrary.CMBPermitsBO.FillTop100() in C:\StrataframeProjects\CMBPermitsBOLibrary\CMBPermitsBO.cs:line 55
       at Editpage.Page_Load(Object sender, EventArgs e) in c:\StrataframeProjects\CMBpermits\Editpage.aspx.cs:line 16
       at System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e)
       at System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e)
       at System.Web.UI.Control.OnLoad(EventArgs e)
       at System.Web.UI.Control.LoadRecursive()
       at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

Replies
Pertti Karjalainen
Pertti Karjalainen
StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)
Group: Forum Members
Posts: 54, Visits: 4K
This is a C# Web application.  I looked at the global.asax -file and commented out SQL and uncommented VFP.  Still experiencing the same *&#*$& problem...
StrataFrame Team
S
StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)
Group: StrataFrame Developers
Posts: 3K, Visits: 2.5K
When you uncommented the VFP data source item, did you change the connection string?  By default it just says "myconnstring"... it needs to be something like this:

Provider=VFPOLEDB;Data Source=C:\MyVfpPath\CPW.DBC;

Pertti Karjalainen
Pertti Karjalainen
StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)StrataFrame User (146 reputation)
Group: Forum Members
Posts: 54, Visits: 4K
Hmmm...  I'm using the SF Object Mapper.  This is the screen sequence of my setup:

Here's how I set up my global.asax:

<%@ Application Language="C#" %>

<%@ Import Namespace="MicroFour.StrataFrame.Data"%>

<script runat="server">

void Application_Start(Object sender, EventArgs e) {

// Code that runs on application startup

// ToDo: 1) Manually set the DataSourceItems on the DataSources collection below.

// -- You can set as many data sources as necessary. The business objects use the data source specified

// by their DataSourceKey property (defaults to "").

//------------------------------------

// Setting the data sources manually

//------------------------------------

//-- SQL Server

//DataLayer.DataSources.Add(new SqlDataSourceItem("", "myconnectionstring"));

//-- Oracle

//DataLayer.DataSources.Add(new OracleDataSourceItem("", "myconnectionstring"));

//-- Microsoft Access

//DataLayer.DataSources.Add(new AccessDataSourceItem("", "myconnectionstring"));

//-- Visual Fox Pro

DataLayer.DataSources.Add(new VfpDataSourceItem("VFPOLEDB", "C:\\CPW\\DATA\\CPW.DBC"));

//Provider=VFPOLEDB;Data Source=C:\MyVfpPath\CPW.DBC;

//-- Set the localization information for the website

MicroFour.StrataFrame.UI.Localization.MessageDataSourceKey = "";

MicroFour.StrataFrame.UI.Localization.MessageLocaleID = 1033;

MicroFour.StrataFrame.UI.Localization.MessageKeyType = MicroFour.StrataFrame.Messaging.MessageKeyDataType.SqlServer;

}

void Application_End(Object sender, EventArgs e) {

// Code that runs on application shutdown

}

void Application_Error(Object sender, EventArgs e) {

// Code that runs when an unhandled error occurs

}

void Session_Start(Object sender, EventArgs e) {

// Code that runs when a new session is started

}

void Session_End(Object sender, EventArgs e) {

// Code that runs when a session ends.

// Note: The Session_End event is raised only when the sessionstate mode

// is set to InProc in the Web.config file. If session mode is set to StateServer

// or SQLServer, the event is not raised.

}

</script>


GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Threaded View
Threaded View
Pertti Karjalainen - 19 Years Ago
StrataFrame Team - 19 Years Ago
Pertti Karjalainen - 19 Years Ago
StrataFrame Team - 19 Years Ago
Pertti Karjalainen - 19 Years Ago
Pertti Karjalainen - 19 Years Ago
StrataFrame Team - 19 Years Ago
StrataFrame Team - 19 Years Ago
Pertti Karjalainen - 19 Years Ago
StrataFrame Team - 19 Years Ago
                         Well, the help file at least I have is almost totally unhelpful on...
Pertti Karjalainen - 19 Years Ago
                             We will get a Getting Started tutorial done on the webforms side that...
StrataFrame Team - 19 Years Ago
                             Perrti, We are always willing to listen to our users and improve our...
Trent L. Taylor - 19 Years Ago
                                 [quote]If I may suggest, someone over there should create a web app...
Trent L. Taylor - 19 Years Ago
                                 [quote][b]Trent L. Taylor (12/12/2006)[/b][hr]Perrti, We are always...
Pertti Karjalainen - 19 Years Ago

Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search