16,018,518 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 Visual Basic questions
View Javascript questions
View .NET 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 gatturamesh (Top 10 by date)
gatturamesh
2-Aug-13 5:20am
View
hey i know about that but my fb login is in main page but when i login in dat page after login it it should redirect to another page
gatturamesh
18-Jul-13 6:51am
View
can u tell me code for downloading a file
gatturamesh
18-Jul-13 3:20am
View
i mean to download a file what i have to write
gatturamesh
18-Jul-13 3:02am
View
if (e.CommandName == "imgClick")
{
//Your Code..
}
what i have ti write in that
gatturamesh
18-Jul-13 2:17am
View
what code i had to write in image button
gatturamesh
18-Jul-13 2:07am
View
hi jaideepsinh ...
i had placed image button in a datalisty not in grid view
gatturamesh
18-Jul-13 1:52am
View
please help me someone it is very urgent to me
gatturamesh
24-Jun-13 7:54am
View
hi here it is the code i had written in button click code
protected void Button1_Click(object sender, EventArgs e)
{
try
{
string filename = Path.GetFileName(FileUpload1.PostedFile.FileName);
FileUpload1.SaveAs(Server.MapPath("~/admin/images1/" + filename));
cn.Open();
SqlCommand cmd = new SqlCommand("animation_page", cn);
cmd.CommandType = CommandType.StoredProcedure;
cmd.Parameters.AddWithValue("@FileName", TextBox1.Text);
cmd.Parameters.AddWithValue("@FilePath", "~/admin/images1/" + filename);
int i = cmd.ExecuteNonQuery();
cn.Close();
if (i == 1)
{
Response.Write("<script type=\"text/javascript\">alert('image inserted succesfully');</script>");
TextBox1.Text = "";
}
else
{
Response.Write("<script type=\"text/javascript\">alert('image not inserted succesfully');</script>");
}
}
catch (SqlException ex)
{
throw ex;
}
}
when i am entering both values it is showing a popup box but when i left upload file field then it is not showing the else part
gatturamesh
24-Jun-13 7:37am
View
Deleted
here it is the code
protected void Button1_Click(object sender, EventArgs e)
{
try
{
string filename = Path.GetFileName(FileUpload1.PostedFile.FileName);
FileUpload1.SaveAs(Server.MapPath("~/admin/images1/" + filename));
con.Open();
SqlCommand cmd = new SqlCommand("animation_page", con);
cmd.CommandType = CommandType.StoredProcedure;
cmd.Parameters.AddWithValue("@FileName", TextBox1.Text);
cmd.Parameters.AddWithValue("@FilePath", "~/admin/images1/" + filename);
int i=cmd.ExecuteNonQuery();
con.Close();
if (i == 1)
{
Lblmsg.Text = "image inserted succesully";
TextBox1.Text = "";
}
else
{
Lblmsg.Text = "Image not inserted ";
}
}
catch (SqlException ex)
{
Lblmsg.Text = "Not Inserted" + ex.Message;
}
}
gatturamesh
24-Jun-13 7:34am
View
can u tell me how to display a popup window withour using ajax controls or validations in java script
Show More