Step 1:
Add reference of Oracle database client library. Right click on “Add Reference”
inside your project. From Add Reference dialog box click on “.Net” tab, select
“System.Data.OracleClient” from Component Name. Click “OK” button to add
reference.
Step 2:
In web.config file
<connectionStrings><add name="ConnectionString" connectionString="Data Source=XE;UserID=system;Password=pintu;Persist
Security Info=True;Connection Lifetime=10" providerName="System.Data.OracleClient"></add></connectionStrings>
Default.aspx code
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="LoginPage_using_Oracle_Db._Default" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
<title>Untitled Page</title>
<script type="text/javascript" language="javascript">
function Validate() {
var UName = document.getElementById('TextBox_user_name');
var Password = document.getElementById('TextBox_password');
if ((UName.value == '') || (Password.value == '')) {
alert('UserName or Password should not be blank');
return false;
}
else {
return true;
}
}
</script>
</head>
<body>
<form id="form1" runat="server">
<div>
<asp:Label ID="lb1" runat="server" Font-Bold="True" ForeColor="#FF3300"></asp:Label><br />
<asp:Label ID="Label2" runat="server" Text="UserName" Font-Bold="True" Width="100px"
BackColor="#FFFF66" ForeColor="#FF3300"></asp:Label>
<asp:TextBox ID="TextBox_user_name" runat="server" ForeColor="#993300" Width="100px"></asp:TextBox><br />
<asp:Label ID="Label3" runat="server" Text="Password" Font-Bold="True" Width="100px"
BackColor="#FFFF66" ForeColor="#FF3300"></asp:Label>
<asp:TextBox ID="TextBox_password" runat="server" ForeColor="#CC6600" TextMode="Password"
Width="100px"></asp:TextBox><br />

Join the conversation! Your thoughts help the community grow.