Re: Deployment + Vista



I know nothing about Vista, but you do not have to bind your connection
string to your strongly typed datasets.

In the display layer of the app, I keep the strongly-typed datasets empty,
then when I need data, I call .Merge() on the strongly typed datasets in
order to return datatables from the appropriate data layer classes. Within
those classes is where I open dynamically created connections.

I deploy a small .xml and .xsd file with the default server name and
database settings (into the app directory), then give the user an input
panel so that they can specify any changes. Separately, I create a class
with separate functions to save and retrieve the settings, and with a couple
of properties for the server and database name. Then I can call a
GetConnectionString() function that calls the retrieval function in order to
put together the connection string something like: m_strConnection = "data
source=" + m_strSQLServerName + ";initial catalog=" + m_strDatabaseName +
";integrated security=SSPI;"

As you can see, the only hard-coded aspect of the string is simply the
security. If necessary, you could even modify that, although if you are
deploying with SqlExpress, you already know what the security setting will
be.

"Steven Spencer (Spinalogic)" <Spence-Spinalogic@xxxxxxxxxxxxxxxx> wrote in
message news:eqTquLrYHHA.984@xxxxxxxxxxxxxxxxxxxxxxx
We use strongly typed datasets, and thus our connection string is bound to
an application setting.

Currently we can deploy and alter the app.exe.config file at installation
time to successfully install, and use some basic XML editing to allow the
target database to be changed.

Writing to the application directory in vista will throw compatibility
errors, and not persist the changes at all.

What do we do? Is there a better way of getting the connection string in
your application, or a way of telling the designer where to get your
connection setting from??



.



Relevant Pages

  • Memory leak with ADO
    ... When the app runs through the loop 2k times about 16-30 megs ... procedure TForm1.SpeedButton1Click(Sender: TObject); ... Caption = 'Connection String' ... object Connection: TADOConnection ...
    (borland.public.delphi.database.ado)
  • Re: Find out the database name from the connection string
    ... If you're already connected to the database, ... going to be any more of a performance hit than string parsing. ... In your app config file, keep the parameters you want separate and then ... There is no magic string parser that will look at a connection string ...
    (microsoft.public.sqlserver.server)
  • Re: ADO connections question
    ... Function CreateADOObjects(ConnectionString as string) ... you'll see this error if the connection has not been ... I have a specific login form that calls the dbLogin function as shown ... Dim strCriteria As String ...
    (microsoft.public.access.adp.sqlserver)
  • Re: Nochmals Treeview
    ... private void button1_Click(object sender, System.EventArgs e) { ... private void TabelleAnlegen(string strDBPfad, string strDB, string strTabellenName){ ... OleDbConnection connection = new OleDbConnection; ... OleDbCommand command = new OleDbCommand; ...
    (microsoft.public.de.german.entwickler.dotnet.csharp)
  • Re: A month with a Nokia n95 (long)
    ... and can't play. ... One of these days I will get around to writing a small app to do it all on the fly. ... HSDPA works well and you can have more than one internet connection going at once. ... For example I can use it as a modem for my laptop and also "listen again" to a Beeb radio programme. ...
    (uk.telecom.mobile)