954,551 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Help in Problem when Connect VB with Oracle 11g / for windows 64 bit

My project is Housing reservation system for University

I design the interfaces by VB and connect to my oracle data base account

Oracle 11g, VB express edition are used

The proble is with the login form
http://im20.gulfup.com/2011-12-23/1324652639153.png
when I debug and enter the ID & password for User :

according to my code :

Imports Oracle.DataAccess.Client
Imports Oracle.DataAccess.Types

Public Class Login_Page
    Dim cn As OracleConnection
    Dim cmd As OracleCommand
    Private Sub Login_Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load


    End Sub

    Private Sub NameLabel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)

    End Sub

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        Dim cn As New OracleConnection
        Dim connString As String = "User Id=08120168;Password=8080;Data Source=dell"
        cn = New OracleConnection(connString)
        Dim ser = CInt(NameTextBox.Text)
        Dim pw = PasswordTextBox.Text
        cn.Open()
        

        cmd = New OracleCommand("SELECT * FROM LOGIN_STUDENT WHERE USER_ID like '%" & ser & "' AND PASSWORD like '%" & pw & "'", cn)

        Dim myreader As OracleDataReader = cmd.ExecuteReader()

        If (myreader.Read() = True) Then

            MessageBox.Show("The user is valid!")
            
            studentpage.Show()        

        Else

            MessageBox.Show("Invalid username or password!")

        End If

    End Sub


it suppose to connect and show the messege:The user is valid

but it does not and a 'FileNotFoundException was unhandled'window appears and running stop and hang
http://im20.gulfup.com/2011-12-23/1324652639151.png
** The same code had been tried in another computers which are 32 bit and work successfuly but in my computer(64 bit) not work.

** Is 32 bit or 64 bit affect ?
** What can i do to solve this problem?
** could any one help

Dorar
Newbie Poster
15 posts since May 2011
Reputation Points: 10
Solved Threads: 0
 

Can you access the database server from the 64-bit machine using sqlplus? If not, perhaps you have not properly installed the Oracle client tools/code on the 64-bit machine?

rubberman
Posting Virtuoso
1,565 posts since Mar 2010
Reputation Points: 277
Solved Threads: 179
 

I'm proberly installed the oracle code even the teacher make sure about it but still the problem in the path

pleaze any one can help
what to do

Dorar
Newbie Poster
15 posts since May 2011
Reputation Points: 10
Solved Threads: 0
 

It may be a Unicode issue in that what you think you are asking for, and what is really on the system are different - single-byte name vs. multi-byte Unicode name. Other than this possibility, I'm out of ideas... :-(

rubberman
Posting Virtuoso
1,565 posts since Mar 2010
Reputation Points: 277
Solved Threads: 179
 

see this link
http://www.daniweb.com/software-development/vbnet/threads/26939


further more try and use ODBC to connect with database. eg

Oracle ODBC Connection String
Driver={Microsoft ODBC for Oracle};Server=myservername;Uid=myusername;Pwd=mypassword;

Oracle OLEDB Connection String
Provider=msdaora;Data Source=mydemodb;User Id=myusername;Password=mypasswd;

Oracle .Net Connection String
Data Source=mydemodb;User Id=myusername;Password=mypasswd;Integrated Security=no;

hope this helps.

dspnhn
Junior Poster in Training
90 posts since May 2008
Reputation Points: 20
Solved Threads: 13
 

This question has already been solved

Post: Markdown Syntax: Formatting Help
You