473,382 Members | 1,107 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,382 software developers and data experts.

A quesion about udl file and app.config

Hi all,
I had created a database connection string in a *.udl file by the connection
setting wizard. And I can easily get the udl file path in my program.And I
don't know why when I set the udl file path as the ConnectionString of the
OdbcConnection it throw an error means like this " unhandle
"System.ArgumentException" Exception appear in system.data.dll.
Other message: from the beginning of the index 0,the format of the
initialize string is not accord with specification"

Is the udl file cannot set as the Conncetion of the data base Connectiong?

By the way , can I set the connectiong string into the app.config? Just
like the setting like web.config.
And whe I set the connectiong into app.config can I use
Configuration.AppSettings["myConnection"] to get the connectiong string from
the app.config file?
Nov 16 '05 #1
1 1949
open the udl file using any simple text editor, you will see some plain
text within which you will also see the connection string. Copy this and
paste it in your code (Copy only stuff in quotations). If it works then
you have trouble reading file.

Jet Leung wrote:
Hi all,
I had created a database connection string in a *.udl file by the connection
setting wizard. And I can easily get the udl file path in my program.And I
don't know why when I set the udl file path as the ConnectionString of the
OdbcConnection it throw an error means like this " unhandle
"System.ArgumentException" Exception appear in system.data.dll.
Other message: from the beginning of the index 0,the format of the
initialize string is not accord with specification"

Is the udl file cannot set as the Conncetion of the data base Connectiong?

By the way , can I set the connectiong string into the app.config? Just
like the setting like web.config.
And whe I set the connectiong into app.config can I use
Configuration.AppSettings["myConnection"] to get the connectiong string from
the app.config file?

Nov 16 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Fuzzyman | last post by:
There have been a couple of config file 'systems' announced recently, that focus on building more powerful and complex configuration files. ConfigObj is a module to enable you to much more *simply*...
2
by: Suresh Gladstone | last post by:
Hi, This is a bit with versioning and installation of the .NET dlls. I want to perform the following, 1. A third party application will be invoking my .NET dll through COM interop . For this I...
4
by: grs | last post by:
Can a class library have a app.config file. Reason for asking is that the microsoft application blocks all read from myApp.exe.config. How can you use the application blocks if you do not have an...
9
by: ALI-R | last post by:
Hi,, I have two questions : 1) Is it mandatory that config file of a desktop application must be App.config 2) Is it possible to update config file in your code?? thanks for your help. ALI
16
by: Timm | last post by:
I'm trying to use ASP objects (basically formed and populated based on Web.Config settings) and I want to use them in a different non-asp program with minimal reprogramming. So, my question is how...
6
by: Rich | last post by:
Hello, I picked up this example on using the Reflection namespace for loading forms/classes on the fly at msdn http://msdn.microsoft.com/library/default.asp?...
3
by: Blasting Cap | last post by:
I am working on a web app that I want to be able to use a separate config file on, in addition to the web.config file that's already working in the application. If I put the following in the...
12
by: dbuchanan | last post by:
Hello, (Is this the proper newsgroup?) === Background === I am building a solution with two projects. One project is my data access layer which contains my DataSet as an xsd file. The XSD...
5
by: mmcd79 | last post by:
I built a VB.net application that makes use of a machine level DB connection string setting, and a user level starting location setting. The machine level setting and the default user based...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.