hi,
After installing the application in the client machine using ClickOnce, i
would like that the client be able to change the
database path in the Application.Config file. However, clickonce does not
copy the Application.Config file when it deploys.
How can i be able to do it, Am i missing something in ClickOnce.
Thanks
Irfan 6 6765
It probably does copy the Application.Config file (it's called app.config).
ClickOnce stuff gets installed under the user's Documents&Settings (XP)
folder somewhere, and it is obfuscated so he can't muck with it. The
app.config file is probably in there somewhere. The problem is, you can't
modify the information in the app.config file with code.
To get around this, I rolled my own settings stuff, with the default for
the ConnectionString hardcoded, and the user can modify it. I store it in
Environment.SpecialFolder.LocalApplicationData + "\myAppName". Then when
the app is upgraded to a new version, I don't lose my settings. This is
also the recommended location by Vista, so you don't have a problem with
Vista security either.
Good luck.
Robin S.
--------------------
"Irfan" <ir***@asc-ltd.co.ukwrote in message
news:Ov**************@TK2MSFTNGP05.phx.gbl...
hi,
After installing the application in the client machine using ClickOnce, i
would like that the client be able to change the
database path in the Application.Config file. However, clickonce does not
copy the Application.Config file when it deploys.
How can i be able to do it, Am i missing something in ClickOnce.
Thanks
Irfan
Rob,
Thanks for the reply.
I have another question:
How do u redirect the program to look at the ConnectionString of YOUR
config file instead the default config file.
irfan
"RobinS" <Ro****@NoSpam.yah.nonewrote in message
news:Fr******************************@comcast.com. ..
It probably does copy the Application.Config file (it's called
app.config). ClickOnce stuff gets installed under the user's
Documents&Settings (XP) folder somewhere, and it is obfuscated so he can't
muck with it. The app.config file is probably in there somewhere. The
problem is, you can't modify the information in the app.config file with
code.
To get around this, I rolled my own settings stuff, with the default for
the ConnectionString hardcoded, and the user can modify it. I store it in
Environment.SpecialFolder.LocalApplicationData + "\myAppName". Then when
the app is upgraded to a new version, I don't lose my settings. This is
also the recommended location by Vista, so you don't have a problem with
Vista security either.
Good luck.
Robin S.
--------------------
"Irfan" <ir***@asc-ltd.co.ukwrote in message
news:Ov**************@TK2MSFTNGP05.phx.gbl...
>hi,
After installing the application in the client machine using ClickOnce, i would like that the client be able to change the database path in the Application.Config file. However, clickonce does not copy the Application.Config file when it deploys.
How can i be able to do it, Am i missing something in ClickOnce.
Thanks Irfan
I don't used strongly typed datasets. I use stored procedures that load
DataSets, and my Data Access layer pulls the connection string from my
config file and uses it when opening the connection.
Are you using strongly typed datasets?
Robin S.
-----------------------
"Irfan" <ir***@asc-ltd.co.ukwrote in message
news:uv**************@TK2MSFTNGP05.phx.gbl...
Rob,
Thanks for the reply.
I have another question:
How do u redirect the program to look at the ConnectionString of YOUR
config file instead the default config file.
irfan
"RobinS" <Ro****@NoSpam.yah.nonewrote in message
news:Fr******************************@comcast.com. ..
>It probably does copy the Application.Config file (it's called app.config). ClickOnce stuff gets installed under the user's Documents&Settings (XP) folder somewhere, and it is obfuscated so he can't muck with it. The app.config file is probably in there somewhere. The problem is, you can't modify the information in the app.config file with code.
To get around this, I rolled my own settings stuff, with the default for the ConnectionString hardcoded, and the user can modify it. I store it in Environment.SpecialFolder.LocalApplicationData + "\myAppName". Then when the app is upgraded to a new version, I don't lose my settings. This is also the recommended location by Vista, so you don't have a problem with Vista security either.
Good luck. Robin S. -------------------- "Irfan" <ir***@asc-ltd.co.ukwrote in message news:Ov**************@TK2MSFTNGP05.phx.gbl...
>>hi,
After installing the application in the client machine using ClickOnce, i would like that the client be able to change the database path in the Application.Config file. However, clickonce does not copy the Application.Config file when it deploys.
How can i be able to do it, Am i missing something in ClickOnce.
Thanks Irfan
yes, I am using stongly typed datasets that creates a readonly
ConnectionString.
However, I deleted that ConnectionString and created a new Property in the
settings file with the SAME name.
This new property pulls the data from the XML file. What do you think about
it? Do you reckon it will
create any problems in future.
irfan
"RobinS" <Ro****@NoSpam.yah.nonewrote in message
news:Fp******************************@comcast.com. ..
>I don't used strongly typed datasets. I use stored procedures that load DataSets, and my Data Access layer pulls the connection string from my config file and uses it when opening the connection.
Are you using strongly typed datasets?
Robin S.
-----------------------
"Irfan" <ir***@asc-ltd.co.ukwrote in message
news:uv**************@TK2MSFTNGP05.phx.gbl...
>Rob, Thanks for the reply. I have another question: How do u redirect the program to look at the ConnectionString of YOUR config file instead the default config file.
irfan
"RobinS" <Ro****@NoSpam.yah.nonewrote in message news:Fr******************************@comcast.com ...
>>It probably does copy the Application.Config file (it's called app.config). ClickOnce stuff gets installed under the user's Documents&Settings (XP) folder somewhere, and it is obfuscated so he can't muck with it. The app.config file is probably in there somewhere. The problem is, you can't modify the information in the app.config file with code.
To get around this, I rolled my own settings stuff, with the default for the ConnectionString hardcoded, and the user can modify it. I store it in Environment.SpecialFolder.LocalApplicationData + "\myAppName". Then when the app is upgraded to a new version, I don't lose my settings. This is also the recommended location by Vista, so you don't have a problem with Vista security either.
Good luck. Robin S. -------------------- "Irfan" <ir***@asc-ltd.co.ukwrote in message news:Ov**************@TK2MSFTNGP05.phx.gbl... hi,
After installing the application in the client machine using ClickOnce, i would like that the client be able to change the database path in the Application.Config file. However, clickonce does not copy the Application.Config file when it deploys.
How can i be able to do it, Am i missing something in ClickOnce.
Thanks Irfan
Well, if it works, that's great. You just have to remember if you recreate
the strongly typed dataset, to delete the ConnectionString again.
Robin S.
-----------------------------
"Irfan" <ir***@asc-ltd.co.ukwrote in message
news:%2****************@TK2MSFTNGP04.phx.gbl...
yes, I am using stongly typed datasets that creates a readonly
ConnectionString.
However, I deleted that ConnectionString and created a new Property in
the settings file with the SAME name.
This new property pulls the data from the XML file. What do you think
about it? Do you reckon it will
create any problems in future.
irfan
"RobinS" <Ro****@NoSpam.yah.nonewrote in message
news:Fp******************************@comcast.com. ..
>>I don't used strongly typed datasets. I use stored procedures that load DataSets, and my Data Access layer pulls the connection string from my config file and uses it when opening the connection.
Are you using strongly typed datasets?
Robin S. ----------------------- "Irfan" <ir***@asc-ltd.co.ukwrote in message news:uv**************@TK2MSFTNGP05.phx.gbl...
>>Rob, Thanks for the reply. I have another question: How do u redirect the program to look at the ConnectionString of YOUR config file instead the default config file.
irfan
"RobinS" <Ro****@NoSpam.yah.nonewrote in message news:Fr******************************@comcast.co m... It probably does copy the Application.Config file (it's called app.config). ClickOnce stuff gets installed under the user's Documents&Settings (XP) folder somewhere, and it is obfuscated so he can't muck with it. The app.config file is probably in there somewhere. The problem is, you can't modify the information in the app.config file with code.
To get around this, I rolled my own settings stuff, with the default for the ConnectionString hardcoded, and the user can modify it. I store it in Environment.SpecialFolder.LocalApplicationData + "\myAppName". Then when the app is upgraded to a new version, I don't lose my settings. This is also the recommended location by Vista, so you don't have a problem with Vista security either.
Good luck. Robin S. -------------------- "Irfan" <ir***@asc-ltd.co.ukwrote in message news:Ov**************@TK2MSFTNGP05.phx.gbl... hi, > After installing the application in the client machine using ClickOnce, i would like that the client be able to change the database path in the Application.Config file. However, clickonce does not copy the Application.Config file when it deploys. > How can i be able to do it, Am i missing something in ClickOnce. > Thanks Irfan > > > >
thanks again Rob
irfan
"RobinS" <Ro****@NoSpam.yah.nonewrote in message
news:hd******************************@comcast.com. ..
Well, if it works, that's great. You just have to remember if you recreate
the strongly typed dataset, to delete the ConnectionString again.
Robin S.
-----------------------------
"Irfan" <ir***@asc-ltd.co.ukwrote in message
news:%2****************@TK2MSFTNGP04.phx.gbl...
>yes, I am using stongly typed datasets that creates a readonly ConnectionString. However, I deleted that ConnectionString and created a new Property in the settings file with the SAME name. This new property pulls the data from the XML file. What do you think about it? Do you reckon it will create any problems in future.
irfan
"RobinS" <Ro****@NoSpam.yah.nonewrote in message news:Fp******************************@comcast.com ...
>>>I don't used strongly typed datasets. I use stored procedures that load DataSets, and my Data Access layer pulls the connection string from my config file and uses it when opening the connection.
Are you using strongly typed datasets?
Robin S. ----------------------- "Irfan" <ir***@asc-ltd.co.ukwrote in message news:uv**************@TK2MSFTNGP05.phx.gbl... Rob, Thanks for the reply. I have another question: How do u redirect the program to look at the ConnectionString of YOUR config file instead the default config file.
irfan
"RobinS" <Ro****@NoSpam.yah.nonewrote in message news:Fr******************************@comcast.c om... It probably does copy the Application.Config file (it's called app.config). ClickOnce stuff gets installed under the user's Documents&Settings (XP) folder somewhere, and it is obfuscated so he can't muck with it. The app.config file is probably in there somewhere. The problem is, you can't modify the information in the app.config file with code. > To get around this, I rolled my own settings stuff, with the default for the ConnectionString hardcoded, and the user can modify it. I store it in Environment.SpecialFolder.LocalApplicationData + "\myAppName". Then when the app is upgraded to a new version, I don't lose my settings. This is also the recommended location by Vista, so you don't have a problem with Vista security either. > Good luck. Robin S. -------------------- "Irfan" <ir***@asc-ltd.co.ukwrote in message news:Ov**************@TK2MSFTNGP05.phx.gbl.. . >hi, >> >After installing the application in the client machine using >ClickOnce, i would like that the client be able to change the >database path in the Application.Config file. However, clickonce does >not copy the Application.Config file when it deploys. >> >How can i be able to do it, Am i missing something in ClickOnce. >> >Thanks >Irfan >> >> >> >> > > This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Danny Tuppeny |
last post by:
I've been playing around with ClickOnce today, and it's all good stuff.
Except, that if I change my application to NOT be full trust (which seems to
make very little difference to the user prompt,...
|
by: M O J O |
last post by:
Hi,
I've have searched google, but can't find a solution to my problem.
Om my develloper machine, I use one app.config, but when I deploy, I need to
deploy another app.config.
The reason...
|
by: Alex Bögli |
last post by:
Hi
I have a rather advanced deployment scenario and wanted to know, if anyone
has an idea how to accomplish that with ClickOnce:
We are deploying a 3-tier application with a client connecting...
|
by: Ronald S. Cook |
last post by:
I have a Win app that references a class library project. Within the
latter, there is a remoting.config file.
When I publish my app using ClickOnce, it errors telling me it can't find
the...
|
by: Peter Wyss |
last post by:
Hello!
I've a few questions about ClickOnce in VisualStudio 2005. The
installation of my application works fine, I published the files on a
webserver and installed the app on a winxp client,...
|
by: Sergio Montero |
last post by:
Hi, I've been googling for a while trying to figure out how to solve this
problem, pleasy, I'll appreciate any sugestions.
I have a Winforms App that should work Online and Offline.
Online...
|
by: Sergio Montero |
last post by:
Hi, I've been googling for a while trying to figure out how to solve this
problem, pleasy, I'll appreciate any sugestions.
I have a Winforms App that should work Online and Offline.
Online...
|
by: jonathonmc |
last post by:
I have a winform app written in C# which accesses a web service using a dynamic URL (configured in the app.config). When I deploy this app via ClickOnce it builds the app.config into the manifest and...
|
by: =?Utf-8?B?QXZpc2hheSBCZW4tWnZp?= |
last post by:
Hi,
I have an application that I am encrypting the connection strings on the
first run of the application. I am using clickonce to deploy the
application, so this was a good solution as the...
|
by: isladogs |
last post by:
The next Access Europe meeting will be on Wednesday 2 August 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM)
The start time is equivalent to 19:00 (7PM) in Central...
|
by: linyimin |
last post by:
Spring Startup Analyzer generates an interactive Spring application startup report that lets you understand what contributes to the application startup time and helps to optimize it. Support for...
|
by: erikbower65 |
last post by:
Here's a concise step-by-step guide for manually installing IntelliJ IDEA:
1. Download: Visit the official JetBrains website and download the IntelliJ IDEA Community or Ultimate edition based on...
|
by: kcodez |
last post by:
As a H5 game development enthusiast, I recently wrote a very interesting little game - Toy Claw ((http://claw.kjeek.com/))。Here I will summarize and share the development experience here, and hope it...
|
by: isladogs |
last post by:
The next Access Europe meeting will be on Wednesday 6 Sept 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM)
The start time is equivalent to 19:00 (7PM) in Central...
|
by: DJRhino1175 |
last post by:
When I run this code I get an error, its Run-time error# 424 Object required...This is my first attempt at doing something like this. I test the entire code and it worked until I added this -
If...
|
by: Rina0 |
last post by:
I am looking for a Python code to find the longest common subsequence of two strings. I found this blog post that describes the length of longest common subsequence problem and provides a solution in...
|
by: Mushico |
last post by:
How to calculate date of retirement from date of birth
|
by: DJRhino |
last post by:
Was curious if anyone else was having this same issue or not....
I was just Up/Down graded to windows 11 and now my access combo boxes are not acting right. With win 10 I could start typing...
| |