15,886,664 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 Pawan Wagh (Top 22 by date)
Pawan Wagh
20-Jul-15 9:34am
View
yup..thnks...!!!
Pawan Wagh
18-Jul-15 4:10am
View
does it mean that..the application which i have developed does not need any changes in code just install on every client machine which are connected to server..or i need to make some changes in my application.
I have read the articles on codeproject about socket programming but didn't grasp the concept.can you help me..
one doubt..does i need an application on server for handling request from client application..
Pawan Wagh
18-Jul-15 4:06am
View
I know my question doesn't make any sense.But you all are experts and you must help or clear the doubts of the beginner like me.
thanks for replying & next time please dont close the question just improve it..
Pawan Wagh
13-Jul-15 10:21am
View
how can i verify that this my clients machine...so that even if some one is having setup of my application he/she won't be able to use it.
Pawan Wagh
29-Jun-15 0:41am
View
using installer class..
Pawan Wagh
28-Jun-15 9:13am
View
local SQL database (.mdf)..point to be noted..client must not have to install SQL server
Pawan Wagh
28-Jun-15 9:00am
View
thanx for your ans..i understand what you are trying to tell me..but,then how should i distribute my application with database embedded in it.
Pawan Wagh
18-Apr-14 16:07pm
View
But i prefer using serverside control....since not so good at client side scripting
Pawan Wagh
18-Apr-14 15:16pm
View
Then how to perform this type of query using sqldatasource
SELECT * FROM STUDENT_TBL WHERE ((Name='%@Name%') OR (Address='%@Address%') OR .......)
Pawan Wagh
14-Apr-14 14:37pm
View
I have solved it myself.......
The select command of sqldatasource2 should be this..
SelectCommand="SELECT * FROM EXPENSE_TBL WHERE ExpenseID=@ExpenseID"
inorder to change record according to selection from gridview....
Pawan Wagh
8-Apr-14 5:49am
View
YES
Pawan Wagh
8-Apr-14 0:57am
View
I understood what u were suggesting me.. thank you for that. but since I am working in asp.net and importing all students name from database in checkboxlist using wizard.....
so I don't know how to achieve this...
Pawan Wagh
7-Apr-14 14:01pm
View
I don't have any idea?
Pawan Wagh
4-Apr-14 16:58pm
View
hey i have solved it and thanx 4 your help.....
protected void CheckBoxList1_DataBound(object sender, EventArgs e)
{
string tooltip = string.Empty;
foreach (ListItem chk in CheckBoxList1.Items)
{
using (SqlConnection con = new SqlConnection(ConfigurationManager.ConnectionStrings["ConnectionString"].ConnectionString))
{
using (SqlCommand cmd = new SqlCommand())
{
try
{
cmd.Connection = con;
cmd.CommandText = "SELECT * FROM Stud_Table WHERE Name='" + chk.Text + "'";
con.Open();
SqlDataReader rd = cmd.ExecuteReader();
while(rd.Read())
tooltip = rd[0].ToString() + Environment.NewLine + rd[1].ToString() + Environment.NewLine + rd[2].ToString();
chk.Attributes.Add("title", tooltip);
}
catch (Exception ex)
{
string error_message = ex.Message;
Response.Write("<script LANGUAGE='JavaScript'>alert('" + error_message + "')</script>");
}
finally
{
con.Close();
}
}
}
}
}
and its working perfect
Pawan Wagh
4-Apr-14 16:03pm
View
it shows nothing in tooltip...just blank
Pawan Wagh
4-Apr-14 15:52pm
View
the details of item in checkboxlist like name,date of birth,address
Pawan Wagh
4-Apr-14 15:18pm
View
i have tried something like this...
protected void Page_Load(object sender, EventArgs e)
{
string tooltip = string.Empty;
foreach (ListItem chk in CheckBoxList1.Items)
{
using (SqlConnection con = new SqlConnection(ConfigurationManager.ConnectionStrings["ConnectionString"].ConnectionString))
{
using (SqlCommand cmd = new SqlCommand())
{
try
{
cmd.Connection = con;
cmd.CommandText = "SELECT * FROM Stud_Table WHERE Name='"+ chk.Text +"'";
con.Open();
SqlDataReader rd = cmd.ExecuteReader();
tooltip = rd[0].ToString() + Environment.NewLine + rd[1].ToString() + Environment.NewLine + rd[2].ToString();
}
catch (Exception ex)
{
string error_message = ex.Message;
Response.Write("<script LANGUAGE='JavaScript'>alert('" + error_message + "')</script>");
}
finally
{
con.Close();
}
}
}
chk.Attributes.Add("title", tooltip);
}
}
Pawan Wagh
2-Apr-14 15:09pm
View
Thanks for your suggestion...i will definitely implement it.
Pawan Wagh
2-Apr-14 14:45pm
View
Thanks for you help but CommandText is not wrong....
I just forget to perform cmd.ExecuteNonQuery() after adding parameter for "INSERT INTO SELECT" query...
Now it's working fine...
Thank you......
Pawan Wagh
2-Apr-14 14:09pm
View
both tables are having same no of columns and datatypes....What i did is---
"INSERT INTO Subject_Table SELECT * FROM Temp_Subject_Table WHERE Stud_Name='@Stud_Name'"..
but not working..
My Code Segment
protected void StudReg_Button_Click(object sender, EventArgs e)
{
using (SqlConnection con = new SqlConnection(ConfigurationManager.ConnectionStrings["ConnectionString"].ConnectionString))
{
con.Open();
SqlTransaction tran = con.BeginTransaction();
try
{
SqlCommand cmd = new SqlCommand();
cmd.Transaction = tran;
cmd.Connection = con;
cmd.CommandType = CommandType.Text;
cmd.CommandText = "INSERT INTO SUBJECTS_TBL SELECT * FROM TEMP_SUBJECT_TBL WHERE Stud_Name='@Stud_Name'";
cmd.Parameters.Add("@Stud_Name", System.Data.SqlDbType.VarChar).Value = this.Session["Stud_Name"].ToString().ToUpper();
cmd.CommandText = "DELETE FROM TEMP_SUBJECT_TBL WHERE Stud_Name='@Del_Stud_Name'";
cmd.Parameters.Add("@Del_Stud_Name", System.Data.SqlDbType.VarChar).Value = this.Session["Stud_Name"].ToString().ToUpper();
cmd.ExecuteNonQuery();
tran.Commit();
}
catch (Exception ex)
{
tran.Rollback();
string error_message = ex.Message;
Response.Write("<script LANGUAGE='JavaScript'>alert('" + error_message + "')</script>");
}
finally
{
con.Close();
}
}
}
It's just deleting not inserting............
Pawan Wagh
31-Mar-14 14:27pm
View
Tried this earlier but not working.data is inserted in temp table but not in subject table after "INSERT INTO SELECT" is performed......
Pawan Wagh
31-Mar-14 14:25pm
View
Yes...But student and subjects table must be separate....
Student adds the subjects required for him before registration and it is stored in temp table....
after registration they are moved to subjects table
Show More