|
aap.config
You have to "add new item" for this.
Specify the connectionstring there.
Example:
<br />
<configuration><br />
<appSettings><br />
<!-- User application and configured property settings go here.--><br />
<!-- Connection string values --><br />
<add key="Provider" value="MSDAORA" /><br />
<add key="DataSource" value="DBTest" /><br />
<add key="UserID" value="Lavanya" /><br />
<add key="Password" value="Password" /><br />
<add key="MailServer" value="EXCH.XYZ.COM"/><br />
</appSettings><br />
</configuration><br />
or
<br />
<connectionStrings><br />
<br />
<add name="ClaimEZ.My.MySettings.BACFConnection" connectionString="Data Source=MYSERVER;Initial Catalog=MYDB;Integrated Security=True" providerName="System.Data.SqlClient" /><br />
<br />
<add name="MyDataLayer.My.MySettings.BACFConnection" connectionString="Data Source=MYSERVER;Initial Catalog=MYDB;Integrated Security=True" providerName="System.Data.SqlClient" /><br />
<br />
</connectionStrings><br />
<br />
PraVeeN
NinethSense.com/blog/
|
|
|
|
|
You don't! Best practice to make the connection to the database only when you need to run a query or modify the tables. The rule of thumb is Connect late, Query fast, Disconnect early. You just don't maintain an open connection to the database for the life of a form or, worse yet, and entire application. With an Access database, maintaining an open connection isn't so bad. But on a real SQL server, that is a VERY expensive connection license you hanging onto and not using.
Get into the habit...
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
i want insert values in datagrid via textbox
i m not connected datagrid to database
if anybody know this please help me
vivek
|
|
|
|
|
A datagrid works only with a DataSet and you should bind this to a DataGrid.
|
|
|
|
|
how can i use mshflexgrid in vb.net
i have add it from com lib but it is not working like visual basic
asdf
|
|
|
|
|
DataBinding goes like this:
Dim objDataSet As New DataSet()
objCommand.Fill(objDataSet)
myDataGrid.DataSource = objDataSet.Tables(0).DefaultView
myDataGrid.VirtualItemCount = GetVirtualItemCount()
myDataGrid.DataBind()
|
|
|
|
|
Update DataSet and bind the DataGrid
PraVeeN
NinethSense.com/blog/
|
|
|
|
|
If I have a jpg file like 1024*768,
but my picturebox only has 800*600,
How can I make the jpg file scale(zoom) to fix the picture box to show?
Thank You!
|
|
|
|
|
|
Sorry for that, I know this property ...
What I really what to know is like a zoom function in All reader,
when we press the (+), the picture zoom in; (-), the picture zoom out.
Thanks anyway.
|
|
|
|
|
Change the SizeMode property of PictureBox to StretchImage.
PraVeeN
NinethSense.com/blog/
|
|
|
|
|
As the title,
I would like to use ghostScript in VB.NET.
I am going to read render PDF in VB.NET or convert it to JPG.
Any reference or article for this purpose.
Thanks a lot.
|
|
|
|
|
First you need to set the printer to one that can either
generate Postscript, or to something like RedMon that can directly
output to Ghostscript.
Second, you need to script Word to print.
PraVeeN
NinethSense.com/blog/
|
|
|
|
|
hi all,
i am trying to do an upload module, which help me to upload files to the database, the module works fine when i run locally, but when i test it on the server, the client side could not upload,when i try to read the file from the client, it returns,
"System.IO.FileNotFoundException: Could not find file "
when executing "file.open" in the line below:
Dim fs As FileStream
fs = File.Open(myFile.FileName, FileMode.Open, FileAccess.Read)
the file exists in the client pc, but it cannot find the file to upload,any idea on how to solve this? thanks in advance
elcheah
|
|
|
|
|
I assume this is only for use on a local network ? And you're passing through a full network path ?
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
thanks for the reply,
i am using a HtmlInputFile, to upload the file from the client, what things should i take care of if this is not just for local network use?
elcheah
|
|
|
|
|
Your best bet is to write a webservice that you can tunnel your files to.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
Hello everyone,
This is my first time using hashes so I'm not all that sure if what I need can be done or is a good thing to do. I'm making a (salted) hash of a unique identifier that will be included in the query string of a link. When the link is followed, I want the page it hits to get that hash value and de-hash it because it contains information that I need for a database query.
All the tutorials I've found show me how to hash data but not unhash it. Can anyone point me in the right direction?
Thanks in advance for your help!
-------------------
abort, retry, fail?
|
|
|
|
|
You can't de-hash a hash code. Hashing is not encryption.
The size of the hash code is limited, but the number of strings that can be hashed is virtually unlimited. That means that there are a lot of strings that gives the same hash code. It's impossible to tell which of the strings created the hash code.
---
b { font-weight: normal; }
-- modified at 16:59 Thursday 12th January, 2006
|
|
|
|
|
Ah, I that makes sense. I'll just figure out some other way to do it without using the hash, then.
Thanks!
-------------------
abort, retry, fail?
|
|
|
|
|
hi
i want to generate the crystal reports with vb.net how
to do that.
ddd
|
|
|
|
|
|
what i want to know is from the basics of using crystal reports in vb.net. for example i had installed .net 2003 and should i install the the crystal report for the .net or it is build in into .net. these kinds of things i want to know.
ddd
|
|
|
|
|
tasleem143 wrote: for example i had installed .net 2003 and should i install the the crystal report for the .net or it is build in into .net.
Well I can't really help you there. It's up to you to research which control will work best for you and your project.
These forums are really for specific coding questions. If you just want to learn about Crystal Reports in general, then your best bet is to read some articles and/or read a book. Crystal Reports is by no means a small topic.
|
|
|
|
|
how to insert date in the access using vb.net.
i m using these code it gives exception
Dim str As String = "#" + Now().ToString("d") + "#"
Dim query As String = "insert into Dt(Date, Val) values ('" & str & "' ,3)"
then then olddbcommand and then executenoquery functions
but that code gives exception
String = "insert into Dt(Date, Val) values (' # 12/3/2006 # ' ,3)"
but that code gives exception
String = "insert into Dt(Date, Val) values ('12/3/2006',3)"
tell me how to do that insert date into access database through
vb.net
ddd
|
|
|
|