15,888,521 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 Commish13 (Top 50 by date)
Commish13
21-Feb-24 11:35am
View
When I do a build there is no error message. But when I run my program the radio button that I select does not work: When I click it; it should display it's value in a modal. Also, the radio button does not show in the designer code.
Commish13
28-Jan-22 11:05am
View
Thanks, but that does not work because the comma is not really part of the value or string
Commish13
20-Aug-19 8:34am
View
Thanks. I will start looking into my stored Procedures and find out whats going on
Commish13
19-Aug-19 20:47pm
View
Thanks for your replies. Is there a way to find out what is slowing down my load time?
Commish13
5-Apr-19 17:23pm
View
Thanks for your help, I got it to work because of your help
Commish13
5-Apr-19 14:52pm
View
If getting an error message in every situation. 1 or both radio buttons checked and when 1 or both are not checked
Commish13
5-Apr-19 14:29pm
View
With this loop my Error message displays with or without the radio button checked
Commish13
5-Apr-19 13:03pm
View
Thank you. I got the solution with the container to work. If you don't mind, could you show me how to do this with a loop? Like I said I have 17 sets of radio buttons.
Commish13
4-Apr-19 14:20pm
View
I'll try to post this issue as a new question. Thanks for your help
Commish13
4-Apr-19 13:25pm
View
When I look at the page source it changes my GroupName to ctl00$ContentPlaceHolder1$Game_1 and even though I try to use that in my script it still does not work correctly. Just to let you know I tried what you suggested but no luck. I tried it in every location I could think of
Commish13
3-Apr-19 19:17pm
View
I found out what is causing the issue. Whenever I use any 1 of your codes with a aspx.page that has a master page attached to it, the validation doesn't work. Whenever I use it on a page without a master page the validation works fine. Do you have any suggests why that is. I did some reverse engineering and made 2 new pages. 1 with just the radio buttons and a blank master page and the code didn't work. I just wanted to make sure nothing on my original master page was causing the problem. It seems that any master page causes this problem.
Commish13
3-Apr-19 17:43pm
View
Repeater won't let me put Class in it
Commish13
3-Apr-19 17:23pm
View
When I put the alert on the JavaScript code the error message say's 'NULL'
When I use the jQuery code the error messages display even when the radio button is checked
Commish13
3-Apr-19 8:28am
View
Ok. I updated my original post
Commish13
2-Apr-19 18:43pm
View
I put my full code up in solution 3 area
Commish13
2-Apr-19 15:32pm
View
Deleted
<%@ Page Title="" Language="C#" MasterPageFile="Site.master" AutoEventWireup="true" CodeFile="PickAllPool.aspx.cs" Inherits="PickAllPool" %>
<asp:content id="HeadContent" contentplaceholderid="head" runat="Server">
function openModal() {
$('#myModal').modal({ show: true });
}
<asp:content id="BodyContent" contentplaceholderid="ContentPlaceHolder1" runat="Server">
Instructions
Payment is $5.00 per week Only 1 entry per week
You CANNOT change picks once they are submitted Submit picks before the start of the first game on Sunday Tie breaker is the Monday Night game total points If you want to pay and be paid through Venmo let us know by using the Contact Us page
<asp:requiredfieldvalidator id="RequiredFieldValidator1" runat="server" errormessage="Full Name is required" controltovalidate="txtFullName" forecolor="#ff0000" setfocusonerror="True" cssclass="errMsg" display="Dynamic">
<asp:regularexpressionvalidator id="RegularExpressionValidator1" runat="server" errormessage="Enter valid Full Name" controltovalidate="txtFullName" forecolor="#ff0000" validationexpression="[a-zA-Z ]*$" setfocusonerror="True" cssclass="errMsg" display="Dynamic">
Full Name
<asp:textbox id="txtFullName" cssclass="form-control" type="text" runat="server" autocompletetype="DisplayName" tabindex="1" placeholder="Required">
<asp:requiredfieldvalidator id="RequiredFieldValidator2" runat="server" errormessage="Text number is required" controltovalidate="txtText" forecolor="#ff0000" setfocusonerror="True" cssclass="errMsg" display="Dynamic">
<asp:regularexpressionvalidator id="RegularExpressionValidator2" runat="server" errormessage="Please enter valid Text Number" controltovalidate="txtText" forecolor="#ff0000" validationexpression="((\(\d{3}\) ?)|(\d{3}))-?\d{3}-?\d{4}" setfocusonerror="True" cssclass="errMsg" display="Dynamic">
Text Number
<asp:textbox id="txtText" cssclass="form-control" type="phone" runat="server" autocompletetype="Cellular" tabindex="2" placeholder="Required">
<asp:requiredfieldvalidator id="RequiredFieldValidator3" runat="server" initialvalue="-- Select --" errormessage="Referred By required" controltovalidate="ddlReferredBy" forecolor="#ff0000" setfocusonerror="True" cssclass="errMsg" display="Dynamic">
Referred By
<asp:dropdownlist id="ddlReferredBy" cssclass="form-control" runat="server" tabindex="3">
<asp:listitem>-- Select --
<asp:listitem value="Killbride">Killbride
<asp:listitem value="McLaughlin">McLaughlin
<asp:listitem value="Nacci">Nacci
<!-- end of form -->
<!---------- Pick All Games ---------->
Left Col
<asp:repeater id="myRepeater" runat="server">
<itemtemplate>
<!---------- Thursday Game ---------->
<asp:panel id="GameThursdayNight" runat="server">
" alt="" />
<%#Eval("ThursdayGameAway")%>
(<asp:label id="lblThursdayGameAwayWins" runat="server">-<asp:label id="lblThursdayGameAwayLost" runat="server">) - away
<asp:radiobutton id="AwayThursday" groupname="ThursdayNightGame" text="<%#Eval("ThursdayGameAway")%>" font-size="0" runat="server" tabindex="4" csscl
Commish13
2-Apr-19 13:46pm
View
No luck. I changed YourRepeaterID to myRepeater and no error message displays
Commish13
2-Apr-19 11:18am
View
I'm not getting a error message. Also, I didn't think it was going to make a difference but it does. I have my radio buttons inside a repeater. So the JavaScript code works good outside the repeater but not inside. Should I re-post my question to include the code inside my repeater?
Commish13
1-Apr-19 18:00pm
View
Thank you. The jQuery code doesn't work. Also on the JavaScript code when neither option in selected the error displays(Good!) But If only 1 option is chosen the error does not display for the remaining the option not selected. Could this be change to look for any option not selected?
Commish13
10-Feb-19 16:31pm
View
How can I get someone else to look at this question?
Commish13
10-Feb-19 15:44pm
View
I appreciate your help but I still don't know how to get the loop and the if statement to work together.
Commish13
10-Feb-19 15:43pm
View
Deleted
.
Commish13
10-Feb-19 12:37pm
View
I kind of don't under stand when you say 'Build a collection of data you do want, and set it as the data source after the loop completes' because I can get each part of my code to work separately but not together.
private void LoadSchedule()
{
string connString = ConfigurationManager.ConnectionStrings["DatabaseConnection"].ConnectionString;
using (SqlConnection conn = new SqlConnection(connString))
{
conn.Open();
using (SqlCommand comm = new SqlCommand("GetSchedule_v2", conn))
{
using (SqlDataReader reader = comm.ExecuteReader())
{
while (reader.Read())
{
DateTime localDate = DateTime.Now.AddHours(2);
DateTime PoolStatusActive = Convert.ToDateTime(reader["PoolActive"]);
DateTime PoolStatusDisabled = Convert.ToDateTime(reader["PoolDisabled"]);
if (localDate > PoolStatusActive && localDate < PoolStatusDisabled)
{
MessageBox.Show("Good");
}
else
{
MessageBox.Show("Bad");
}
}
}
}
}
}
or
private void LoadSchedule()
{
string connString = ConfigurationManager.ConnectionStrings["DatabaseConnection"].ConnectionString;
using (SqlConnection conn = new SqlConnection(connString))
{
conn.Open();
using (SqlCommand comm = new SqlCommand("GetSchedule_v2", conn))
{
using (SqlDataReader reader = comm.ExecuteReader())
{
myRepeater.DataSource = reader;
myRepeater.DataBind();
}
}
}
}
Commish13
10-Feb-19 12:02pm
View
I just want to thank you for your help but is there any way you could give me a code example. I'm trying to follow your comment above but no matter what I try it's not working.
Commish13
9-Feb-19 16:58pm
View
Hi, I'm trying to use your code but running into another issue. Whenever I put my repeater into the if statement it doesn't populate myRepeater. I need the if statement to display the pool at a certain date and time and not display after a certain date and time. Whenever I debug my code it steps through with any problems but it doesn't display my pool on the web page. Just to let you know the date and time are set up good so it will display the pool.
private void LoadSchedule()
{
string connString = ConfigurationManager.ConnectionStrings["
DatabaseConnection"].ConnectionString;
using (SqlConnection conn = new SqlConnection(connString))
{
conn.Open();
using (SqlCommand comm = new SqlCommand("GetSchedule_v2", conn))
{
using (SqlDataReader reader = comm.ExecuteReader())
{
while (reader.Read())
{
DateTime localDate = DateTime.Now; ;
DateTime PoolStatusActive = Convert.ToDateTime(reader["PoolActive"]);
DateTime PoolStatusDisabled = Convert.ToDateTime(reader["PoolDisabled"]);
if (localDate > PoolStatusActive && localDate < PoolStatusDisabled)
{
myRepeater.DataSource = reader;
myRepeater.DataBind();
reader.Read();
}
}
}
}
}
Any suggestions what I should do or change?
Thanks
Commish13
9-Feb-19 10:49am
View
Thanks for your reply. Just wondering is it good practice to use a try, catch?
Commish13
22-May-18 20:22pm
View
Thank you your second code works great!
Commish13
22-May-18 15:51pm
View
Ok. I understand what your saying. This will validate if the radio button rbOption1 is selected. But, I'm trying to validate if 1 of the 2 radio buttons are selected than it would be valid. That's why I was trying to use the GroupName. Is there a way I could validate these 2 radio buttons at the same time to ensure 1 of the 2 options are selected?
Commish13
22-May-18 15:33pm
View
Sorry but the ("Game_1") should have been ("gnOption1"). I'm trying to validate to that 1 of the 2 radio buttons must be selected.
Commish13
19-May-18 16:56pm
View
Thank you, I don't know if you saw my other 2 comments before I deleted them but I figured it out. Thanks for the code it really helped.
Commish13
19-May-18 16:51pm
View
Deleted
Sorry I was wrong about my above comment. As of now its showing the Id numbers in the separate columns. I would like to show the teams names.
Whenever I try this I get the error:
Conversion failed when converting the nvarchar value 'Eagles' to data type int.
Commish13
19-May-18 16:41pm
View
Deleted
Yes, Very close. But in order for me to display this data on my site I need to have the columns names to be HomeTeam and AwayTeam. Right now they are in 2 different columns but the same name TeamName
Thanks for your help. I'm trying to do this now but still having trouble
Commish13
1-May-18 19:22pm
View
Thanks, With your code I was able to get the results in needed. I am having trouble displaying the Total or Points on my site. I'm playing with it now but if you have any suggestions it would be appreciated.
Thanks for you help with the above code
Commish13
26-Apr-18 12:54pm
View
I have 2 different tables that accept users picks for each game and a table that holds the winners of the games. Each users picks and winners of each game is in a row format. I'm having trouble displaying a Win or Lost next to the users picks depending on the result of the game.
Commish13
26-Apr-18 12:49pm
View
This statement produces the same results. When the first game is correct it also displays the rest of the games are correct even though some of the other games are incorrect. Same thing if the first game is incorrect then it displays the rest of the games incorrect
Commish13
16-Jan-18 22:12pm
View
Thank you, that works perfectly
Commish13
30-May-17 14:52pm
View
Yes I sew that, but they use the SELECT and when I try to use CREATE I get the Error Msg
Commish13
7-Nov-14 15:22pm
View
No errors. Just doesn't go to the correct location.
Commish13
7-Nov-14 15:22pm
View
I will now. Didn't know there was one.
Commish13
13-Sep-14 21:43pm
View
Thanks for your answer. It's a great high level explanation of what I need to do. Unfortunately for me I'm an entry level C# guy, so I'm going to have to use Google to find out how to write code for this project. Do you have any suggestion on what this project is called, or any key words I should use? Once again thanks for the great over view of what I need to do.
Commish13
17-Mar-14 20:24pm
View
Not looking for MS standards. Looking for more of if the code would work. Also. I'm not sure if this code is something I would write in a class, console, or code in separate file. I also am pretty sure that 'var' is wrong when declaring a variable in C#. I thought 'var' is used in JavaScript. Any help would be appreciated. Thanks
Commish13
17-Mar-14 20:01pm
View
Deleted
It's a home work question. I'm supposed to comment on what is good or bad about the code
Commish13
22-Nov-13 19:33pm
View
I'm using the code above but I think I'm put the wrong value in this line here:
dt=getdata();//here getdata() method returns data from database;
I put
Dim dt As New DataTable()
grdEmp.DataSource = dt
Session("data") = dt
Whenever I run my program I get an error message saying it can't find the Column(Which ever Column header I click on)
I'm very new at this so could someone let me know exactly I should type in there.
Commish13
18-Nov-13 10:50am
View
I really wasn't trying to find the exact code I need but, I'm trying to find a Sort Code that does NOT use a ViewState. Reason being, I have a Gridview that has a Filter/Search feature so every time I try to Sort my Filter results the ViewState displays the non filter page then Sorts the column. I did post a code that I was trying to use, but I didn't get any response back of why the code wasn't working.This is the link to my post:
http://www.codeproject.com/Questions/683258/GridView-Sorting-without-DataSource
Commish13
17-Nov-13 18:22pm
View
I thank you for your reply but, These examples use a ViewState. I'm using a Filter/Search feature on my GridView so every time I filter then Sort the column it clears out my Filter results.
Commish13
16-Nov-13 10:34am
View
Yes. But every time I try to find something the code is using a DataSet. My code is only displaying records using a DataTable in a GridView. Also I don't want to use a View State code because I'll be editing the records.
Commish13
15-Nov-13 12:06pm
View
I populated the GridView but now I'm trying to make the columns sort by clicking on the header. Do you know of any tutorials or have code that could help me make this possible?
Commish13
15-Nov-13 10:17am
View
I just got it to work. I make the changes you suggested and Thava and it works perfectly. Thanks for your help
Commish13
15-Nov-13 10:17am
View
I just got it to work. I make the changes you suggested and tmik and it works perfectly. Thanks for your help
Commish13
15-Nov-13 9:40am
View
I thank you for your help. I did make the changes you suggestions but I'm still getting the 'No Records Found' message. Is there something else that could be missing?
Show More