Solved

Sharepoint 2010 calculated column help

Posted on 2013-01-16
2
865 Views
Last Modified: 2013-01-16
OK, I have somebody just come ask me if I can add a calculated column to do the following to one of their sharepoint 2010 lists....

Existing column called ReportPeriod, Single line of Text, input mask of "\d\d\-\d\d\d\d"

So field always contains something like "02-2013"

They would like a single calculated field adding that will display the NEXTreportingPeriod, based on 12 periods per calendar year.

So in the above example, the NextReportingPeriod will be "03-2013"

Must handle "12-2013" giving "01-2014"

Anybody give a single formula for this?

Thanks in advance, i hope,

Neilsr
0
Comment
Question by:Neil Russell
2 Comments
 
LVL 44

Accepted Solution

by:
Rainer Jeschor earned 500 total points
ID: 38782398
Hi,

please try this one:
=IF(ISBLANK(ReportPeriod),"",TEXT(DATE(YEAR(ReportPeriod),MONTH(ReportPeriod)+1,1),"mm-yyyy"))

Open in new window


HTH
Rainer
0
 
LVL 37

Author Closing Comment

by:Neil Russell
ID: 38782530
Spot on, saved me the time :P
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When installing SharePoint 2010 RTM I came across a strange error, I was getting timeouts during the installation. I searched the web and found the best solution to be found here (http://social.msdn.microsoft.com/Forums/en-US/sharepoint2010genera…
SharePoint Designer 2010 has tools and commands to do everything that can be done with web parts in the browser, and then some – except uploading a web part straight into a page that is edited in SPD. So, can it be done? Scenario For a recent pr…
Microsoft Active Directory, the widely used IT infrastructure, is known for its high risk of credential theft. The best way to test your Active Directory’s vulnerabilities to pass-the-ticket, pass-the-hash, privilege escalation, and malware attacks …
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…

821 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question