Click here to Skip to main content
16,021,464 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
hi my friends.
i want set shamsi date in first textbox and next textbox shows 3day after today.
(without component)
thanks.
Posted
Comments
[no name] 4-Jun-14 14:54pm    
http://www.codeproject.com/Articles/12672/Shamsi-Convertor
ZurdoDev 4-Jun-14 15:18pm    
What is your question?
Mohammad Hasanpoor 4-Jun-14 15:34pm    
i write code below that show shamsi date.
now i want another label shows 3 day after today.
ZurdoDev 4-Jun-14 15:38pm    
That seems pretty easy though right? If you already have 1 date just add 3 to get a date 3 days later, right?
Mohammad Hasanpoor 4-Jun-14 16:25pm    
i did it. but has problem. because we can not control the month.

1 solution

If you don't get what you want from these articles you could leave a comment for the authors...

Persian DateTime[^]
PersianDate Library that Returns value and Converts System.DateTime[^]
 
Share this answer
 
Comments
Mohammad Hasanpoor 4-Jun-14 15:22pm    
sorry. i use this function to show.

public string miladi2shamsi(DateTime _date )
{
PersianCalendar pc=new PersianCalendar();
StringBuilder sb=new StringBuilder();
sb.Append(pc.GetYear(_date).ToString("0000"));
sb.Append ("/");
sb.Append (pc.GetMonth(_date ).ToString("00"));
sb.Append ("/");
sb.Append(pc.GetDayOfMonth(_date).ToString("00"));
return sb.ToString();
}


now how can i show 3 days after date of day?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900