16,004,806 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 .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 Nkhanedzeni (Top 23 by date)
Nkhanedzeni
25-Jun-21 15:07pm
View
It seems Parallel.ForEach will make things easier. I did a bit of digging and i come up with the below. I want to add to this list
List<rate> rates = new List<rate>();
Parallel.ForEach(insertDestinations, destination => {
//Now i am not sure how i can continue base on my Foreach statement. Can you please assist?
});
Nkhanedzeni
25-Jun-21 5:40am
View
I have fixed it by removing extra param.
How can i optimize this as well
foreach (var destination in insertDestinations)
{
Rate rate = new Rate()
{
DestinationGroup = rateSheetSummary.Description,
Description = rateSheetSummary.Description,
DestinationId = destination.DestinationId,
Country = rateSheetSummary.CountryCode,
TariffId = tariffId,
NextPrice = rateSheetSummary.Peak,
Price = rateSheetSummary.Peak,
Interval = 1,
Discontinued = "N",
Forbidden = "N"
};
rates.Add(rate);
}
Nkhanedzeni
25-Jun-21 5:36am
View
It is giving me this error: "No overload method 'Contains' takes two arguments"
Nkhanedzeni
7-Jun-21 8:07am
View
Thanks, why is it adding the backslash or will it work like this?
"\"testing1\",\"testing2\",\"testing3\",\"testing4\",\"testing5\",\"testing6\""
Nkhanedzeni
16-Jan-20 8:35am
View
Thank you, it worked like a champ
Nkhanedzeni
20-Aug-14 4:21am
View
Thanks for your reply and now am starting to understand...can you please give me some good references like links which i can learn to create win forms class...Thanks
Nkhanedzeni
7-Aug-13 5:07am
View
thanks now working....don't u know how to make it change color to red if it is invalid character?
Nkhanedzeni
7-Aug-13 4:58am
View
I have used for numeric but it keeps on showing error message for both numbers and letters
Nkhanedzeni
26-Jul-13 4:37am
View
owk.
Nkhanedzeni
26-Jul-13 4:30am
View
Thanks, for sure this will help me
Nkhanedzeni
26-Jul-13 4:16am
View
Thanks let me google as i still don't understand you
Nkhanedzeni
16-Jul-13 5:18am
View
i have already use Convert.ToDate....
date e.g 27/12/2011
Nkhanedzeni
16-Jul-13 4:47am
View
date input....
here is the format i used under the grid view;
foreach (MCX.FASNew.BaseDALC.Plan.VMemberPlanDetails _vGetvMemberPlanList in _vGetvMemberPlan)
{
txtInceptionDate.Text = String.Format("{0:dd/MM/yyyy}", _vGetvMemberPlanList.InceptionDate);
CboMemberName.SelectedValue = _vGetvMemberPlanList.MemberID.ToString();
CboPlanName.SelectedValue = _vGetvMemberPlanList.PlanID.ToString();
ViewState["MemberPlanID"] = _vGetvMemberPlanList.MemberPlanID.ToString();
}
then under the button i used your codes;
protected void btnDelete_Click(object sender, EventArgs e)
{
string date = txtInceptionDate.Text;
DateTime dttxtInceptionDate = DateTime.Parse(date);
//DateTime dttxtInceptionDate1 = DateTime.Parse(txtInceptionDate.Text.Trim());
_daPlan.InsertMemberPlan(3, int.Parse(ViewState["MemberPlanID"].ToString()), int.Parse(CboMemberName.SelectedValue), int.Parse(CboPlanName.SelectedValue), true, dttxtInceptionDate);
FetchData();
ViewState["MemberPlanID"] = "";
txtInceptionDate.Text = "";
CboPlanName.SelectedIndex = 0;
CboMemberName.SelectedIndex = 0;
}
Nkhanedzeni
16-Jul-13 4:39am
View
Hi Chimcham... it gives this kind of the error again
System.FormatException: String was not recognized as a valid DateTime. at System.DateTimeParse.Parse(String s, DateTimeFormatInfo dtfi, DateTimeStyles styles) at System.DateTime.Parse(String s) at Administration_Manage_Members_FormsView_MemberPlan.btnSubmit_Click(Object sender, EventArgs e)
Nkhanedzeni
16-Jul-13 4:27am
View
thanks, let me try...
Nkhanedzeni
6-Jun-13 6:32am
View
From the code below...show me how to write it
protected void txtID_TextChanged(object sender, EventArgs e)
{
foreach (char cr in txtID.Text)
{
if (char.IsDigit(cr) == false)
{
Console.Write("Invalid Charactor"","Error Message")
}
}
Nkhanedzeni
6-Jun-13 6:29am
View
so i must not use Console.Write()?
Nkhanedzeni
6-Jun-13 6:25am
View
why are you using Console.Write() ? it does not allows me to write Messagebox likke on windows forms
Nkhanedzeni
6-Jun-13 6:21am
View
It is just for learning purpose since i knew by coding
Nkhanedzeni
6-Jun-13 6:16am
View
thanks......working
Nkhanedzeni
6-Jun-13 6:02am
View
Thanks let me try this....i will get back to you soon
Nkhanedzeni
6-Jun-13 5:44am
View
Thanks....do you have any idea on what will be the problem with my coding?
Nkhanedzeni
6-Jun-13 5:16am
View
only numbers on ID textbox
Show More