15,911,785 members
Sign in
Sign in
Email
Password
Forgot your password?
Sign in with
home
articles
Browse Topics
>
Latest Articles
Top Articles
Posting/Update Guidelines
Article Help Forum
Submit an article or tip
Import GitHub Project
Import your Blog
quick answers
Q&A
Ask a Question
View Unanswered Questions
View All Questions
View C# questions
View C++ questions
View Javascript questions
View Visual Basic questions
View Python questions
discussions
forums
CodeProject.AI Server
All Message Boards...
Application Lifecycle
>
Running a Business
Sales / Marketing
Collaboration / Beta Testing
Work Issues
Design and Architecture
Artificial Intelligence
ASP.NET
JavaScript
Internet of Things
C / C++ / MFC
>
ATL / WTL / STL
Managed C++/CLI
C#
Free Tools
Objective-C and Swift
Database
Hardware & Devices
>
System Admin
Hosting and Servers
Java
Linux Programming
Python
.NET (Core and Framework)
Android
iOS
Mobile
WPF
Visual Basic
Web Development
Site Bugs / Suggestions
Spam and Abuse Watch
features
features
Competitions
News
The Insider Newsletter
The Daily Build Newsletter
Newsletter archive
Surveys
CodeProject Stuff
community
lounge
Who's Who
Most Valuable Professionals
The Lounge
The CodeProject Blog
Where I Am: Member Photos
The Insider News
The Weird & The Wonderful
help
?
What is 'CodeProject'?
General FAQ
Ask a Question
Bugs and Suggestions
Article Help Forum
About Us
Search within:
Articles
Quick Answers
Messages
Comments by Er Atul Sharma (Top 9 by date)
Er Atul Sharma
15-May-15 4:04am
View
Hi,
can you send this code to me please, i have a similar issue and need to print directly to printer, on my mail id is atulsharmaaa1987@gmail.com ASAP., its urgent to me.
Er Atul Sharma
25-Jul-13 5:16am
View
Reason for my vote of 5 \n my vote 5
Er Atul Sharma
4-May-13 7:06am
View
my problem is not solve now but you will help to me for solving my problem.
Er Atul Sharma
2-May-13 8:53am
View
1 is what?
Er Atul Sharma
2-May-13 8:41am
View
Deleted
i am unable to past all code, i can send email to if u provide email id
Er Atul Sharma
2-May-13 8:39am
View
Deleted
this is my code
<pre lang="c++">
public partial class logint : System.Web.UI.Page
{
string ConnString;
int musr_ClientID = Convert.ToInt32(null);
OleDbDataAdapter oleDbDataAdapter1 = new OleDbDataAdapter();
protected void Page_Load(object sender, EventArgs e)
{
//----- To Stop Caching of Secure Pages.
Response.Cache.SetCacheability(HttpCacheability.NoCache);
lblCustomMessage.Text = "";
ConnString = ConfigurationManager.ConnectionStrings["con"].ConnectionString.ToString();
if (((int)Session["LoginCount"] + 1) < ((int)Session["MaxLoginAttempts"]))
{
}
else
{
lblCustomMessage.Text = "You Have Exceeded The 'Maximum Allowed Attempts' Limit. ";
//ADD Code to mail and update data Base For login Exceeded
}
if (Session["LoggedIn"] == null)
txtUser.Focus();
else
{
pnlLogin.Visible = false;
pnlClentList.Visible = true;
BindClientList();
}
if (!Page.IsPostBack)
{
}
}
protected string ValidateEntries()
{
string ErrorList = String.Empty;
if (txtUser.Text == "")
{
ErrorList = "-Please Enter User Name";
if (txtPassword.Text == "")
ErrorList += "\n-Please Enter Password.";
}
else
{
if (String.Compare(txtUser.Text, "DEMO", true) == 0)
{
//---- Bypass Password.
}
else
{
if (txtPassword.Text == "")
ErrorList += "\n-Please Enter Password.";
}
}
return ErrorList;
}
protected void ProcessLogin(object sender, EventArgs e)
{
if (((Button)sender).ID == "cmdClear")
return;
string ErrorList = ValidateEntries();
if (ErrorList != String.Empty)
{
myMessageBox.MessageBox.Show(ErrorList);
}
else
{
try
{
DataSet ds = new DataSet();
DataSet ds1 = new DataSet();
try
{
string sSql = "select * from MEPS_USER where MUSR_CODE = '" + txtUser.Text.Trim() + "'";
DbSQLLink dbLink = new DbSQLLink();
ds = dbLink.GetSQLData(sSql);
string validUser = ds.Tables[0].Rows.Count.ToString();
if (validUser == "0")
{
myMessageBox.MessageBox.Show("-Invalid User");
txtUser.Focus();
//--- Track the number of login attempts ---//
int loginCount = (int)Session["LoginCount"];
loginCount += 1;
Session["LoginCount"] = loginCount;
//------------------------------------------//
}
else
{
string DecryptedPassword = String.Empty;
DecryptedPassword = EncryptDecrypt.Decrypt_Password(ds.Tables[0].Rows[0]["MUSR_PASSWORD"].ToString().Trim());
string EncryptedPassword = String.Empty;
EncryptedPassword = EncryptDecrypt.Encrypt_Password(txtPassword.Text.ToString().Trim());
if (((ds.Tables[0].Rows[0]["MUSR_PASSWORD"].ToString().Trim()) == EncryptedPassword))
{
//Checking User Active or not
int activeUser = Convert.ToInt16(ds.Tables[0].Rows[0]["MUSR_NOT_ACTIVE"].ToString());
if (activeUser == 1)
{
myMessageBox.MessageBox.Show("Invalid User");
txtUser.Text = "";
Er Atul Sharma
2-May-13 8:25am
View
Deleted
Hi Ankur,
In our application,we use datasourceid, if i will remove it then there is any problem, can be face or not
my code:-
<td valign="top" style="height: 612px">
<rsweb:ReportViewer ID="ReportViewer1" width="100%" height="100%" runat="server" Font-Names="Verdana" Font-Size="8pt" ShowFindControls="False" >
<localreport reportpath="Reports\PatientLedger.rdlc">
<datasources>
<rsweb:reportdatasource datasourceid="ObjectDataSource1" name="PatientLedger_Patient" xmlns:rsweb="#unknown">
<rsweb:reportdatasource datasourceid="ObjectDataSource1" name="PatientLedger_PaymentDetails" xmlns:rsweb="#unknown">
<rsweb:reportdatasource datasourceid="ObjectDataSource1" name="PatientLedger_ClientDetails" xmlns:rsweb="#unknown">
</td>
Er Atul Sharma
2-May-13 8:24am
View
Deleted
Hi Ankur,
In our application,we use datasourceid, if i will remove it then there is any problem, can be face or not
my code:-
<td valign="top" style="height: 612px">
<rsweb:ReportViewer ID="ReportViewer1" width="100%" height="100%" runat="server" Font-Names="Verdana" Font-Size="8pt" ShowFindControls="False" >
<localreport reportpath="Reports\PatientLedger.rdlc">
<datasources>
<rsweb:reportdatasource datasourceid="ObjectDataSource1" name="PatientLedger_Patient">
<rsweb:reportdatasource datasourceid="ObjectDataSource1" name="PatientLedger_PaymentDetails">
<rsweb:reportdatasource datasourceid="ObjectDataSource1" name="PatientLedger_ClientDetails">
</td>
Er Atul Sharma
26-Apr-13 7:13am
View
Thanks for help
Show More