.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
david stephan
Gaurav Pal
Post New Web Links

Cannot convert from 'int' to 'System.Data.OracleClient.OracleParameter' - Problem with OracleHel

Posted By:      Posted Date: September 07, 2010    Points: 0   Category :ASP.Net
Hi I downloaded the OracleHelper.cs & I use VisualStudio 2008,I'm suppose to pass values to a stored procedure which accepts 2 parametersWhen i pass from codebehind it says,Cannot convert from 'int' to 'System.Data.OracleClient.OracleParameter'Cannot convert from 'string' to 'System.Data.OracleClient.OracleParameter'The best overloaded method match for 'DataWrapper.ExecuteNonQuery(string, System.Data.CommandType, string, params System.Data.OracleClient.OracleParameter[])' has some invalid argumentsI'm posting mycode,Using STORED PROCEDURE,OracleHelper.ExecuteNonQuery (con, CommandType.StoredProcedure, "sample", Int32.Parse(TextBox1.Text),TextBox2.Text); Plz help !______________________________________If possible,  tell me a solution for this error too !http://forums.asp.net/t/1598804.aspx

View Complete Post

More Related Resource Links

How to convert System.Type to Data.DbType?

Hi,Is it possible to convert a System.Type to Data.DbType (this is unfortunately an enumaeration)?Thanks, Rainer.

Data Type Convert problem?

1/2 is inputed by user, I hope to get the result 0.5, but both Method1 and Method2 get the result 0 How can I do? Thanks! BTW, I can't require user to input 1.0/2.0      Method1:     double my = 1/2;Method2:     double my = Convert.ToDouble(1/2);  

System.Data.OracleClient Depreciation in .net 4.0


hello everyone,

Till now i was using asp.net 2.0 and vb.net 2.0 with oracle 10g to maintain and develop a complex software.My primary focus of this problem is oracle connection. Earlier i was using  System.Data.OracleClient  for making connections to database. Now i m goin to upgrade the whole source code to .net 4.0(asp.net and vb.net both) however database is not gonna change(Oracle 10g only). Microsoft data provider  System.Data.OracleClient  is depriciated in .net 4.0. It says i have to use ODN.NET or third party data providers. I wanna know how to use ODN.NET with .net 4.0 and oracle 10g.

Problem with 'System.Data.SqlClient.SqlParamterCollection'


Hello guys,

I'm just a newbie developer using C# (ASP.Net) I'm having trouble in finding the solution in my error:

'System.Data.SqlClient.SqlParameterCollection' does not contain a definition for 'AddWithValue' accepting first argument of type 'System.Data.SqlClient.SqlParameterCollection' could be found (are you missing a directive or an assembly reference?)

I am using parameters before, but never experienced this kind of error.

Thanks in advance!

Is System.Data.OracleClient.dll deprecated?


I have a web application that has been using the System.Data.OracleClient.dll for the past 3 years. Recently we've been having some performance issues on the database server and it appears that this app is now causing problems when connecting to our Oracle database.

I've found an updated client at the Oracle website: http://www.oracle.com/technetwork/topics/dotnet/index-085163.html

My question is: Is it necessary for me to update to this new client?

We are running Oracle 11g on 64-bit servers in a cluster.

The app is running on a Windows Server 2008 R2 64-bit machine using ASP.NET 4.0. The app was built using Visual Studio 2005 Team Suite on a 32-bit machine. It was re-compiled on a 64-bit machine and imported into Visual Studio 2010 Professional in order to switch the target framework to .NET 4.0. Then it was deployed to the server. This basically updated the Web.config file for us, the rest of the site remains the same as before.

All suggestions and thoughts are welcome.


Is there a 64-bit version of System.Data.OracleClient?

We have several ASP.NET applications that are currently running on 32-bit Windows Server 2003 machines.  Most of our code was written using Microsoft's System.Data.OracleClient library rather than Oracle's Oracle.DataAccess library. 

We are in the process of upgrading to new 64-bit machines running Windows Server 2008.  Is there a 64-Bit version of System.Data.OracleClient, or do we need to convert all of our applications to use Oracle.DataAccess?  We do not want to run WOW as we desire to convert all of our ASP.NET applications to run in IIS as 64-bit.

Thank you.

32 Bit ASP.Net App using System.Data.OracleClient trying to load 64 bit System.Data.OracleClient?


We have a ASP.Net app.
We run it in 32 bit on Prod because we have a Dundas Control that can only run in 32 bit.

This application uses out-of-the-box System.Data.OracleClient.

But on prod it seems to be trying to load the 64 bit version. Our app-pool is set to 32 bit.
I would think it would know to load the 32 bit version of System.Data.OracleClient.  But it doesn't.

We do have Oracle's 64 bit Oracle.DataAccess.OracleClient installed on Prod because most of our apps run in 64 bit and our newer apps use Oracles's DataProvider.

Does anyone know how to get a 32 bit app to load the 32 bit System.Data.OracleClient so I don't have to go back into the code and change all of this to the ODP driver?  Even that won't work because the ODP.Net driver is 64 bit and our Dundas App runs in 32 bit.

This is the actual error we get:


[BadImageFormatException: An attempt was made to load a program with an incorrect format. (Exception from HRESULT: 0x8007000B)]

[InvalidOperationException: Attempt to load Oracle client libraries threw BadImageFormatException.  This problem will occur when running in 64 bit mode with the 32 bit Oracle client components installed.]

But this is the reverse of our pro

Problem upgrading to MVC3 - System.Web.Routing



I'm trying to upgrade to .NET 4 and MVC 3.

When trying to compile my project, I get the error:

Error 1 The type or namespace name 'Routing' does not exist in the namespace 'System.Web' (are you missing an assembly reference?) C:\Users\spencer\Desktop\weblauncher\Common\MVCConfig.cs 4 18 Common

The type or namespace name 'Routing' does not exist in the namespace 'System.Web' (are you missing an assembly reference?)

I do have the System.Web.Routing in my references for the project.

BUT - when I try to view System.Web.Routing in the OBJECT BROWSER, nothing is inside!  The System.Web.Routing namespace is not in there - the entire thing is empty!  Could it that the dll is corrupted?  I tried to reinstall the .NET 4 and MVC 3 stuff, but its still empty!

The dll is coming from here:

C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0\System.Web.Routing.dll

and the runti

The type 'System.Data.Linq.DataContext' is defined in an assembly that is not referenced. You must



This is frustrating, and I don't know how to solve it.

I have a strange problem. I am adding a LinqDatasource object, and set the context:

        protected void LinqDataSource_ContextCreating(object sender, LinqDataSourceContextEventArgs e)
            e.ObjectInstance = new KaruselaDataContext(ConfigurationManager.ConnectionStrings["ConnectionString"].ConnectionString);

Then I get this error:
The type 'System.Data.Linq.DataContext' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Data.Linq, Version=, Culture=neutral, PublicKeyToken=b77a5c561934e089'.


On web.config I already have this:
<add assembly="System.Data.Linq, Version=, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>

NOTE: The datacontext is in a different project (DLL proect) where I added a refernce to System.Data.Linq.

is there another way adding a refernce to a web project? or only though teh web.config?


MySql.Data assembly problem



I added refernece MySql.Data to my project. My web.config looks like that:

<?xml version="1.0"?>
                <add assembly="MySql.Data, Version=, Culture=neutral, PublicKeyToken=C5687FC88969C44D"/>

But when in ServerExplorer I try "Add Connection..." I can't find "MySql Database" in the "Choose Data Source" dialog box?

What the problem can be?

convert SQL data to EDI 835 file


I was assigned to create a app to convert SQL data to EDI 835 file. (Electronic Data Interchange file for Health Care Claim Payment/Advice,  outbound process only).

Can someone help me where to start?

Crystal Report vs 2003 convert to vs 2008 parameter problem


Hi friend,

I have a project develop with Visual Studio 2003, when i convert the project to Visual Studio 2005 is work well. But when i convert to Visual Studio 2008, the crystal report when have pass parameter will prompt the parameter field to re-type then show the report.

But in this converted project i create a new report and pass the parameter is ok. That means i wan re-do all report @.@??

Does someone can help me solve this problem??

Thank you

Data Points: Revisiting System.Transactions


The System.Transactions namespace of the Microsoft .NET Framework makes handling transactions much simpler than previous techniques. Read all about it this month.

John Papa

MSDN Magazine November 2006

Data Points: ADO.NET and System.Transactions


The Microsoft® . NET Framework versions 1. 0 and 1. 1 represented major changes in software development. However, one important thing that did not change much was support for distributed transactions.

John Papa

MSDN Magazine February 2005

Exchange 2000 WSS: Web Storage System Improves Exchange Data Accessibility


The Web Storage System (WSS) in Exchange 2000 is a Web-accessible database that stores any type of data such as e-mail, contacts, appointments, threaded discussions, and multimedia files, and renders the data in HTML in any browser. WSS is based on Internet standards, therefore data can be accessed through URLs, an Exchange OLE DB provider, drive mapping, XML, and Web Documenting and Versioning (WebDAV). This article discusses the WSS schema and how to extend the default schema for custom data. A sample application that uses a custom schema and a custom form to display WSS data is available for download.

Sean McCormick

MSDN Magazine May 2001

problem...i want a list item to populate all data in gridview!!!


i have a dropdownbox and a gridview

what I want is to have a list item which populates all data in a gridview.

I have tried using list item selected value=0 but to no avail.

what is the easiest way to achieve this?

Business Data Error: System.OverFlowException


I have a Business Data Catalog file I've uploaded to connect to our back end Firebird DBMS through ODBC.

The SharePoint server is MOSS 2007 x64. The web front end server(s) all have an x64 Firebird Engine and ODBC driver with verified connectivity to Firebird.

When I use one of the methods, I can see connections being made to our Firebird server and the query being passed. I know the query returns results (it's a stored procedure with no parameters), but I get the following error "An error occurred while retrieving data from MROTest1. Administrators, see the server log for more information" in IE. If I look in the server logs, I see (12\Hive\Logs)

Exception handed to HandleRuntimeException.HandleException System.OverflowException: Arithmetic operation resulted in an overflow.     at System.Data.Odbc.OdbcDataReader.GetData(Int32 i, SQL_C sqlctype, Int32 cb, Int32& cbActualOut)
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend