How to Set Application Path

Please support our VB.NET advertiser: Intel Parallel Studio Home
Reply

Join Date: Sep 2008
Posts: 29
Reputation: sganandhsg is an unknown quantity at this point 
Solved Threads: 1
sganandhsg sganandhsg is offline Offline
Light Poster

How to Set Application Path

 
0
  #1
Nov 11th, 2008
hi friends

How to set application path using VB.Net using MySQL.....

The same function using VB 6.0 as
Public AttnPath As String
AttnPath = App.Path & "\Data" this type, i need vb.net help me plz...






Regards
Anandh
Reply With Quote Quick reply to this message  
Join Date: Apr 2008
Posts: 54
Reputation: Pgmer is an unknown quantity at this point 
Solved Threads: 5
Pgmer Pgmer is offline Offline
Junior Poster in Training

Re: How to Set Application Path

 
0
  #2
Nov 11th, 2008
In vb.net u need to use the property called Application.StartupPath="path u want to give"
Reply With Quote Quick reply to this message  
Join Date: Sep 2008
Posts: 29
Reputation: sganandhsg is an unknown quantity at this point 
Solved Threads: 1
sganandhsg sganandhsg is offline Offline
Light Poster

Re: How to Set Application Path

 
0
  #3
Nov 11th, 2008
Originally Posted by Pgmer View Post
In vb.net u need to use the property called Application.StartupPath="path u want to give"


Thanks for ur replay.. I`ll use this but error msg displayed for " Property is "startuppath " is Read only"
Reply With Quote Quick reply to this message  
Join Date: Jul 2008
Posts: 65
Reputation: Renukavani is an unknown quantity at this point 
Solved Threads: 6
Renukavani Renukavani is offline Offline
Junior Poster in Training

Re: How to Set Application Path

 
0
  #4
Nov 11th, 2008
Originally Posted by sganandhsg View Post
Thanks for ur replay.. I`ll use this but error msg displayed for " Property is "startuppath " is Read only"
hi
u have specify like
Application.StartupPath + " u can specfy remaining path here"
Application.startuppath means it wil show upto bin folder then concatenate with this " u can specfy remaining path here"

if ur probelm solved plz mark as solved
Reply With Quote Quick reply to this message  
Join Date: Apr 2008
Posts: 54
Reputation: Pgmer is an unknown quantity at this point 
Solved Threads: 5
Pgmer Pgmer is offline Offline
Junior Poster in Training

Re: How to Set Application Path

 
0
  #5
Nov 11th, 2008
yes Ur correct application.startuppath will give you the path where Ur executable files are there in the machine.
Application.StartupPath + " the desired path u want to be"
Last edited by Pgmer; Nov 11th, 2008 at 5:27 am.
Reply With Quote Quick reply to this message  
Join Date: Sep 2008
Posts: 29
Reputation: sganandhsg is an unknown quantity at this point 
Solved Threads: 1
sganandhsg sganandhsg is offline Offline
Light Poster

Re: How to Set Application Path

 
0
  #6
Nov 11th, 2008
Originally Posted by Pgmer View Post
yes Ur correct application.startuppath will give you the path where Ur executable files are there in the machine.
Application.StartupPath + " the desired path u want to be"
Any Declare Variable contain This Path
Reply With Quote Quick reply to this message  
Join Date: Jul 2008
Posts: 65
Reputation: Renukavani is an unknown quantity at this point 
Solved Threads: 6
Renukavani Renukavani is offline Offline
Junior Poster in Training

Re: How to Set Application Path

 
0
  #7
Nov 11th, 2008
hi
i tried like this for ur ?
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
TextBox1.Text = Application.StartupPath()
End Sub
or

Application.StartupPath & "\\DataBase\\dbname.db"
Last edited by Renukavani; Nov 11th, 2008 at 5:55 am.
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC