Click here to Skip to main content
15,897,187 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Manually registering .tlb files Pin
Eddy Vluggen16-Aug-12 2:48
professionalEddy Vluggen16-Aug-12 2:48 
GeneralRe: Manually registering .tlb files Pin
Karthik Chintala16-Aug-12 2:53
Karthik Chintala16-Aug-12 2:53 
GeneralRe: Manually registering .tlb files Pin
Eddy Vluggen16-Aug-12 13:51
professionalEddy Vluggen16-Aug-12 13:51 
GeneralRe: Manually registering .tlb files Pin
Karthik Chintala16-Aug-12 18:46
Karthik Chintala16-Aug-12 18:46 
GeneralRe: Manually registering .tlb files Pin
Eddy Vluggen16-Aug-12 22:27
professionalEddy Vluggen16-Aug-12 22:27 
Questionupdate app.config file Pin
VINCENT20545415-Aug-12 11:10
VINCENT20545415-Aug-12 11:10 
SuggestionRe: update app.config file Pin
Shameel16-Aug-12 1:58
professionalShameel16-Aug-12 1:58 
Questionupdate app.config file Pin
VINCENT20545415-Aug-12 10:40
VINCENT20545415-Aug-12 10:40 
i have the app i want users to set connection to the database at run time by supplying the data source name,user id and password of the database before the application set. This is what i have done but it seem not to get me the exit output i want.any help?

Public Sub savenewconnection(ByVal id As String, ByVal pass As String, ByVal source As String)
Try
Dim newdbcon As String
Dim oldconnection As ConnectionStringSettings = ConfigurationManager.ConnectionStrings("mydbcon")
Dim dbcon As String = oldconnection.ConnectionString
Dim builder As New OleDbConnectionStringBuilder(dbcon)
builder.Add("Data Source", source)
builder.Add("Password", pass)
builder.Add("User ID", id)
newdbcon = builder.ConnectionString
Dim config As System.Configuration.Configuration = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None)
config.ConnectionStrings.ConnectionStrings("mydbcon").ConnectionString = newdbcon
config.Save(ConfigurationSaveMode.Modified)
ConfigurationManager.RefreshSection("ConnectionStrings")

Catch ex As Exception
MsgBox(ex.Message)
End Try
End Sub
AnswerRe: update app.config file Pin
Wes Aday15-Aug-12 10:49
professionalWes Aday15-Aug-12 10:49 
QuestionPath/File access error Pin
No-e15-Aug-12 3:59
No-e15-Aug-12 3:59 
AnswerRe: Path/File access error Pin
derek999915-Aug-12 4:33
derek999915-Aug-12 4:33 
GeneralRe: Path/File access error Pin
No-e15-Aug-12 4:36
No-e15-Aug-12 4:36 
GeneralRe: Path/File access error Pin
Аslam Iqbal15-Aug-12 8:26
professionalАslam Iqbal15-Aug-12 8:26 
GeneralOT: Sweet signature... Pin
Paul Conrad15-Aug-12 7:26
professionalPaul Conrad15-Aug-12 7:26 
GeneralRe: OT: Sweet signature... Pin
derek999915-Aug-12 22:23
derek999915-Aug-12 22:23 
GeneralRe: OT: Sweet signature... Pin
Paul Conrad16-Aug-12 6:54
professionalPaul Conrad16-Aug-12 6:54 
QuestionRe: Path/File access error Pin
Eddy Vluggen15-Aug-12 5:26
professionalEddy Vluggen15-Aug-12 5:26 
AnswerRe: Path/File access error Pin
No-e15-Aug-12 8:39
No-e15-Aug-12 8:39 
AnswerRe: Path/File access error Pin
Dave Kreskowiak15-Aug-12 8:07
mveDave Kreskowiak15-Aug-12 8:07 
QuestionSimple program exceptions on all other win7 platforms Pin
Uranium-23514-Aug-12 19:22
Uranium-23514-Aug-12 19:22 
AnswerRe: Simple program exceptions on all other win7 platforms Pin
Bernhard Hiller14-Aug-12 21:06
Bernhard Hiller14-Aug-12 21:06 
QuestionUsing VB.Net printing Pin
DWprogrammer14-Aug-12 8:18
DWprogrammer14-Aug-12 8:18 
AnswerRe: Using VB.Net printing Pin
Eddy Vluggen15-Aug-12 1:13
professionalEddy Vluggen15-Aug-12 1:13 
QuestionVisual Studio Expenses Project Pin
garyu8714-Aug-12 5:16
garyu8714-Aug-12 5:16 
AnswerRe: Visual Studio Expenses Project Pin
Eddy Vluggen15-Aug-12 1:21
professionalEddy Vluggen15-Aug-12 1:21 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.