Showing posts with label properly. Show all posts
Showing posts with label properly. Show all posts

Monday, March 26, 2012

The ConnectionString property has not been initialized

Hi all,

I have developed a web page using asp.net. When testing ( debugging ) it from the VS 2005 it works properly.

In the load of the page I created a SqlConnection and specified the ConnectionString

The problem is when calling the page from a Fox Pro 9.0 application I get this message:

The ConnectionString property has not been initialized.

It seems that when calling the page from Fox Pro the ConnectionString is written incorrectly in the load method of the page

So does anyone have any suggestion?

Regards

Could you please specify the connection string over here. Also make sure that you have used new keyword while defining the connection string

Regards,

Suhas


Hi,

There is a article onconnection string here.

Saturday, March 24, 2012

The DataSet: I have doubts

Here are my doubts about the dataSet object. These doubts may arise from my not understanding this object properly so please let me know if this is the case.

i see these problems:

1. if a user closes the page mid session i lose my in memory dataSet so all the dataGrid editing my user has done since the database was last updated is lost.

2. when updating the parent database I need to fill the dataAdapter first in case anyone else has edited the rows beforehand. all this toing and froing is expensive.

Also, how do i decide to update the parent database from the dataSet. Can I do it automatically i.e. on a timer or do I do it after every 5 dataGrid row edits?

thanks.1. You would lose any data had you hand written the text boxes and filled the table dynamically with them. It's not the fault of the DataSet or some weird communication.

2. Again, you should be checking data validity before hand any way. The only difference here, with DataGrids, is that you know exactly which row was modified before hand very easily.

3. [How do I...] Why not whenever the user presses update? The few times that I have used datasets I have never held them in the session. I bind them to a datagrid and forget. When the user edits, the info I need to update the row is right there.