Sometimes we have to develop an automatized routine that must run in an specific schedule in your SharePoint site. This routine must complete some tasks, send e-mails, whatever… you name it! That’s why we develop SharePoint Timer Jobs and they work quite well.
If you know how they work, you probably know they are usually deployed with a Feature Receiver that adds to the Farm during the deployment process.
But let’s say if your SharePoint administrator forgot to activate it and you had to do it manually. Or if you are in an development environment and you want to debug the Feature receiver to find a bug.
So you are browsing to the Manage Features page, you find the feature and then suddenly an exception happens presenting a message of Access Denied!
Sometimes we need to transfer a list from a Production environment to a Development environment, just to reproduce some bug or situation with real data. It can achieve by the Save as Template feature, exporting it from an environment to another and then recreating the list.
But, if you have Lookup fields it can give you some headaches. As soon as the list is restored in the other environment, the Internal Guids are changed an any connection to the source list of the lookup column will be lost:
The option Get information from will be empty and the column name will be a span, not a a dropdown. where you could select which field should be presented:
Today I would like to share with you an useful way to troubleshoot errors in your SharePoint site when some unexpected error occurs.
You will need two things: the Correlation Id and access to Powershell or SharePoint Management Shell on the server. Once you got these two things, just paste the code below replacing the CorrelationId parameter with your Id.
This example is extremely simple, but saved my life a thousand times. The Get-SPLogEvent accepts other parameters too like Start and End Time too, that will help you on filtering better. Here is how the Log will be formatted in the text file.