473,320 Members | 1,977 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Could not create an environment: OCIEnvCreate returned -1.

1
I am getting the error while I am trying to connect to Oracle with my code in ASP.NET, this code is working in another machine, but it fails in my laptop, giving the below error.

Could not create an environment: OCIEnvCreate returned -1.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Exception: Could not create an environment: OCIEnvCreate returned -1.

Source Error:


Line 71: Dim objCmd As New OracleCommand
Line 72:
Line 73: objConn.Open()
Line 74: objCmd.Connection = objConn
Line 75: objCmd.CommandText = strSQL


Source File: C:\Inetpub\wwwroot\IFB\clsITODatabase.vb Line: 73

Stack Trace:


[Exception: Could not create an environment: OCIEnvCreate returned -1.]
System.Data.OracleClient.DBObjectPool.GetObject(Ob ject owningObject, Boolean& isInTransaction)
System.Data.OracleClient.OracleConnectionPoolManag er.GetPooledConnection(String encryptedConnectionString, OracleConnectionString options, OracleConnection owningObject, Boolean& isInTransaction)
System.Data.OracleClient.OracleConnection.OpenInte rnal(OracleConnectionString parsedConnectionString, Object transact)
System.Data.OracleClient.OracleConnection.Open()
IFB.clsITODatabase.CreateDataReaderOracle(String strSQL) in C:\Inetpub\wwwroot\IFB\clsITODatabase.vb:73
IFB.clsITODatabase.authenticateUser(String strUserID) in C:\Inetpub\wwwroot\IFB\clsITODatabase.vb:162
IFB.Global.Session_Start(Object sender, EventArgs e) in C:\Inetpub\wwwroot\IFB\Global.asax.vb:77
System.Web.SessionState.SessionStateModule.RaiseOn Start(EventArgs e)
System.Web.SessionState.SessionStateModule.OnStart (EventArgs e)
System.Web.SessionState.SessionStateModule.Complet eAcquireState()
System.Web.SessionState.SessionStateModule.BeginAc quireState(Object source, EventArgs e, AsyncCallback cb, Object extraData)
System.Web.AsyncEventExecutionStep.System.Web.Http Application+IExecutionStep.Execute()
System.Web.HttpApplication.ExecuteStep(IExecutionS tep step, Boolean& completedSynchronously)


---------------------

I am tried all the options given through many resources which I searched in the net, still my problem persists, I have given the permissions to the ASPNET user to the Oracle directory, still I have this problem, any suggestions, even the oracle data provider is installed. Any suggestions please reply to me asap.

Thanks
Mohins
May 8 '07 #1
1 5879
RedSon
5,000 Expert 4TB
If it works on one machine but not on the other, that leads me to believe that it is a problem with the setup or permissions on your oracle database. I will move this to the oracle folks to see if they will be better able to help you.
May 8 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: ben | last post by:
Below is the error message I am receiving on a production server with the Oracle 9.2 client installed. However, on a Oracle 9.0 client installation on the development server the problem does not...
1
by: Edward | last post by:
I've installed an in-house application that was developed with VB.NET that connects to a Oracle Database (version ). I've installed the Oracle client (version 9i) on the machine that is running the...
4
by: Maria Paz | last post by:
Hi, I install Visual Studio .net. When I try to create a windows application, this error happended: "Visual C# .Net Compiler could not be created" I understand that missing something or I not...
1
by: BuddyWork | last post by:
Hello, When a particular user (has administrator rights) on a Windows 2000 Server SP4 tries to run any MSI's we get the message mentioned in the subject. If we logon with another user that has...
13
by: Thom Little | last post by:
My first ASP.NET application on Visual Studio 2005 and .NET Framework 2.0 The application compiles and executes correctly on the development machine. I then publish it to an empty directory on...
0
by: Big Charles | last post by:
Hello, I have an ASP.NET 1.1 web application running in a Windows Server 2003. Connects to Oracle 10g through Oracle 10g Client. Data base in another server. But I can't connect web application...
2
by: Dale Sampson | last post by:
My app uses an ODBC connection for a .mdb file. I want the app to create the source if it does not already exist (I copy a blank .mdb file to the users data store if it doesn't exist). I see how...
7
by: Scott McNair | last post by:
Hi, I'm trying to set an environment variable programmatically. I've added these three lines to my code: System.Environment.SetEnvironmentVariable("TCS", "C:\Program Files\TCS\") InstallPath...
1
by: Claire | last post by:
Ive written a small string resource building utility that I send out to our translators. I have a setup project for each language we support, which picks out a group of 12 english resx files plus...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.