[Mono-dev] facing problems while running VB.Net application on Mono in Linux
Singh, Narendra Kumar
Narendra.Singh at ps.net
Sun May 28 23:51:53 EDT 2006
Hi ,
Actually we have developed an application which connects to Oracle 10G
and accesses some tables.
The application is working fine when it is build with Visual; Studio.Net
2003
But the sample application is not working on Linux in Mono
The error is as follows
Unhandled Exception: System.DllNotFoundException: oci
in <0x00053> (wrapper managed-to-native) OciNativeCalls:OCIEnvCreate
(intptr&,System.Data.OracleClient.Oci.OciEnvironmentMode,intptr,intptr,i
ntptr,intptr,int,intptr)
in <0x00020> System.Data.OracleClient.Oci.OciCalls:OCIEnvCreate
(intptr&,System.Data.OracleClient.Oci.OciEnvironmentMode,intptr,intptr,i
ntptr,intptr,int,intptr)
in <0x0005d> System.Data.OracleClient.Oci.OciEnvironmentHandle:.ctor
(System.Data.OracleClient.Oci.OciEnvironmentMode)
in <0x0003c> System.Data.OracleClient.Oci.OciGlue:CreateConnection
(System.Data.OracleClient.OracleConnectionInfo)
in <0x0002b> System.Data.OracleClient.OracleConnection:Open ()
in <0x0004f> (wrapper remoting-invoke-with-check)
System.Data.OracleClient.OracleConnection:Open ()
in <0x0006a> Test:Main (string[])
and the code is as follows:
Imports System.Data
Imports System.Data.OracleClient
Public Class Form1
Inherits System.Windows.Forms.Form
#Region " Windows Form Designer generated code "
Public Sub New()
MyBase.New()
'This call is required by the Windows Form Designer.
InitializeComponent()
'Add any initialization after the InitializeComponent() call
End Sub
'Form overrides dispose to clean up the component list.
Protected Overloads Overrides Sub Dispose(ByVal disposing As
Boolean)
If disposing Then
If Not (components Is Nothing) Then
components.Dispose()
End If
End If
MyBase.Dispose(disposing)
End Sub
'Required by the Windows Form Designer
Private components As System.ComponentModel.IContainer
'NOTE: The following procedure is required by the Windows Form
Designer
'It can be modified using the Windows Form Designer.
'Do not modify it using the code editor.
Friend WithEvents ListBox1 As System.Windows.Forms.ListBox
<System.Diagnostics.DebuggerStepThrough()> Private Sub
InitializeComponent()
Me.ListBox1 = New System.Windows.Forms.ListBox
Me.SuspendLayout()
'
'ListBox1
'
Me.ListBox1.Location = New System.Drawing.Point(72, 48)
Me.ListBox1.Name = "ListBox1"
Me.ListBox1.Size = New System.Drawing.Size(104, 95)
Me.ListBox1.TabIndex = 0
'
'Form1
'
Me.AutoScaleBaseSize = New System.Drawing.Size(5, 13)
Me.ClientSize = New System.Drawing.Size(292, 266)
Me.Controls.Add(Me.ListBox1)
Me.Name = "Form1"
Me.Text = "Form1"
Me.ResumeLayout(False)
End Sub
#End Region
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
Dim con As New OracleConnection("Password=userdummy;User
ID=dummyuser;Data Source=dot")
con.Open()
Dim da As New OracleDataAdapter("select USERID from dbuser",
con)
Dim ds As New DataSet
da.Fill(ds, "dbuser")
ListBox1.DataSource = ds.Tables("dbuser")
ListBox1.DisplayMember = "USERID"
End Sub
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs)
End Sub
End Class
Please suggest some ways to solve this problem
Regards
Girish
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-devel-list/attachments/20060529/cc3b8b31/attachment.html
More information about the Mono-devel-list
mailing list