Click here to Skip to main content
15,891,253 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
In MVC4 c# i need to generate the academic period yearwise
for eg:
the year period is given below
2015-2016

2016-2017

2017-2018

how to generate the code for these years.Means how to get the current year and add the the next year

pls help me
Posted

1 solution

You want us to teach you how to add one to a number?

C#
int year = 2015;
int nextYear = year + 1;


Please at least learn the basics of a programming language before attempting any real projects or asking questions, a forum is not a good place to learn something from scratch.
 
Share this answer
 
Comments
Athul MS 30-Jul-15 4:53am    
its not my question how to dynamically select these years in dropdownlist
drop down items
2015-2016

2016-2017

2017-2018

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