List Info

Thread: RE: App Path




RE: App Path
country flaguser name
United States
2007-03-05 10:28:56
Hi Tim....ithanks....t's going to take some time for me to learn visual basic 2005...and has anyone seen how vb9 looks???well, it's not good old classic vb6 anymore, it's more like c#...
And btw, just to rant a bit... while Microsoft promied to support vb6 applications on Vista they didn't ship all the dll's that your programs might need, so it's a big headache. Anyone using Vista yet or deploying applications to Vista?
 
Jamie

Timothy Rupp <tim.ruppgmail.com&gt; wrote:
Jamie,
VB.Net doesn’t support the app.path function of VB6.
One way you could replicate it, is to use this function:
Private Function AppPath() as String
 &nbsp; &nbsp; &nbsp; &nbsp;   ; &nbsp; &nbsp; Return System.Windows.Forms.Application.StartupPath
End function
/tr

From: helpwithvbyahoogroups.com [mailto:helpwithvbyahoogroups.com] On Behalf Of Mindserve
Sent: Monday, March 05, 2007 9:13 AM
To: Helpwithvb
Subject: [helpwithvb] App Path
Good Morning everyone....Normally I use the following to connect to the database so it's not hard coded.
XXX  "PROVIDER=Microsoft.Jet.OLEDB.4.0;Data Source=" & App.Path & "SS2X.MDB;Persist Security Info=False"
This is returning an error in Visual Basic 2005 which I am just beginning to learn...
Below is a sample of a connection to vb2005 which does work , so how do you change the path so that is is the applications path and not hard coded to the C drive....Jamie
____________________________________________________________
Private Sub frmMain_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
m_cnADONetConnection.ConnectionString = _
"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:Documents and SettingsXtremeblueDesktopTYVB2005SamplesHour 21contacts.mdb"
m_cnADONetConnection.Open()
m_daDataAdapter = _
New OleDb.OleDbDataAdapter("Select * From Contacts", m_cnADONetConnection)
m_cbCommandBuilder =
New OleDb.OleDbCommandBuilder(m_daDataAdapter)
m_daDataAdapter.Fill(m_dtContacts)
Me.ShowCurrentRecord()
End Sub
 

Be a PS3 game guru.
Get your game face on with the latest PS3 news and previews at Yahoo! Games.



 


Need Mail bonding?
Go to the Yahoo! Mail Q&A for great tips from Yahoo! Answers users. __._,_.___ __,_._,___
RE: Vista scares me (was "App Path")
country flaguser name
United States
2007-03-05 11:00:06
Me?  I am avoiding Vista until AT LEAST Service Pack 1,
Maybe 2.
One article in  a computer magazine extorts folks to upgrade
to Vista now, since they will be doing so eventually, and so
get the benefits of this new OS earlier.
 
A recent article in Forbes absolutely took Vista apart
(along with Office 2007, although to a lesser extent). 
Problems (IIRC):
1) Whole new way of organizing menus, with no
"classic" option, 2) small number of nontrivial
incompatibilities with old files, libraries, 3) loss of
support for some older, but still in play device drivers, 5)
Others that I don't recall.
 
-BDN
--------
 
And btw, just to rant a bit... while Microsoft promised to
support vb6 applications on Vista they didn't ship all the
dll's that your programs might need, so it's a big headache.
Anyone using Vista yet or deploying applications to Vista?
 
Jamie



------------------------ Yahoo! Groups Sponsor
--------------------~--> 
Something is new at Yahoo! Groups.  Check out the enhanced
email design.
http://us.click.yahoo.com/kOt0.A/gOaOAA/yQLSAA/k7folB/TM

------------------------------------------------------------
--------~-> 

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://grou
ps.yahoo.com/group/helpwithvb/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://
groups.yahoo.com/group/helpwithvb/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:helpwithvb-digest@yahoogroups.com 
    mailto:helpwithvb-fullfeatured@yahoogroups.com

<*> To unsubscribe from this group, send an email to:
    helpwithvb-unsubscribe@yahoogroups.com

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.c
om/info/terms/
 

  
[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )