Skip to Main Content

Oracle Developer Tools for Visual Studio

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Oracle TNS server error in VB6 and Windows 7

2911555Mar 25 2015 — edited Mar 26 2015

HI,

We have some legacy VB6 applications developed in windows server 2000. These projects connect to oracle 9i database.The code use Oracle in Proc type library 4.0 and connect to oracle using Oracle session object.

We are in process of setting up these codes in our new development environment hosting windows 7 (64 bit)

Oracle 9i client was installed in compatibility mode in windows 7. TNSNAMES.Ora was same as what used in our windows 2000 environment(both SQLNET and TNSNAMES.ORA).

Connecting to 9i datbase base SQLPLUS and SQL developer are working fine. even TNSPING gives OK result while testing in windows 7

However when we debug/connect from the code, the OraSession code fails giving "ORA 12154-COuld not resolve Sevice Name". The paths for Oracle are given in environment paths(including TNS_ADMIN path).

Below code works in Windows 2000(32 bit OS) and fails in Windows7(both environment has oracle 9i client)

Set OraSession = CreateObject("OracleInProcServer.XOraSession")

Set OraDatabase = OraSession.DbOpenDatabase("OurDB", "scott/tiger", 0&)

Someone help me to understand how to make this code connect to oracle in Win7?

Thanks

Guhan

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 23 2015
Added on Mar 25 2015
6 comments
2,395 views