I deployed a SharePoint feature that has an Event Receiver and ran into this error when trying to update the Today Column during a nightly batch run. The Error occured on random Document Libray items. So I did some research and found out that I needed to update the Event Receiver to run as Synchonous when Updating items. This solved the problem! By default Event Receivers run Asynchrounsly, which is not always ideal, especially in this situation.
To fix this problem just update the Element.xml file for the Event Receiver in question for the event type (Updating) you want to run as Synchronous as follows. Then redeploy. Be sure to Deactivate and Activate the site feature once it has been redeployed since it might not be used everywhere.
<Synchronization>Synchronous</Synchronization> under Elements -> Receivers -> Receiver tag
Also in my nightly batch job I used the following code to disable Events when Updating... The Using Code is further down the page.
//Disables Events when updating
using (var scope = new DisabledItemEventsScope())
{
SPList list = oWebsite.Lists["Code Rules"];
//This must be switched on, otherwise the Update method will throw an exception.
collWebsite[i].AllowUnsafeUpdates = true;
for (int k = list.Items.Count - 1; k >= 0; k--)
{
SPListItem item = list.Items[k];
//This only Works if the List Item was manually Updated before using a column called Today.
item.Properties["Today"] = DateTime.Now.Date.ToString(CultureInfo.InvariantCulture);
//SystemUpdate Updates without changing the Modified Time OR Modified By and DOES NOT make a New Version!
item.SystemUpdate(false);
}
collWebsite[i].AllowUnsafeUpdates = false;
}
#region DisabledItemEventsScope
/// <summary>
/// Disabled item events scope
/// </summary>
/// <see cref="https://adrianhenke.wordpress.com/2010/01/29/disable-item-events-firing-during-item-update/"/>
class DisabledItemEventsScope : SPItemEventReceiver, IDisposable
{
bool oldValue;
public DisabledItemEventsScope()
{
this.oldValue = base.EventFiringEnabled;
base.EventFiringEnabled = false;
}
#region IDisposable Members
public void Dispose()
{
base.EventFiringEnabled = oldValue;
}
#endregion
}
#endregion DisabledItemEventsScope
Good Luck!
3b8a60ac-2bd7-46b6-bf5c-574b5f52a0c5|0|.0
- Type in secpol.msc /s
- Select "Local Policies" in MSC snap in
- Select "User Rights Assignment"
- Right click on "Log on as batch job" and select Properties
- Click "Add User or Group", and include the relevant user.
I'm posting this as some idiot at a stupid company (you know who you are!!) changed a Global Group policy and it broke the permissions for the Service Account used to run Task Manager Jobs.
Good Luck!
89eb13f5-a8d0-4fee-a55e-ccc20fe04dd3|0|.0
1. Run regedit
2. Go to HKEY_CURRENT_USER\Software\Microsoft\Office\15.0\Common (repeat for muliple versions of MS Office)
3. Create a KEY called "Security" here by right clicking on the Common key and selecting New->Key and typing "Security"
4. Create a DWORD in the Security key by right clicking on Security, selecting New->DWORD and type in "DisableHyperlinkWarning"
5. Change the value of this DWORD to 1
23539960-2579-4af4-a954-1029b21fd2f2|0|.0
Someone created a VM for me recently and everyime I launched IE to get to our SharePoint site internally I was being prompted to login. So I changed the IE Setting to use my credentials to log in automatically. That was OK for the time I was on the VM. BUT, when I went back in it asked me again and my settings in IE had been reverted.
This was so annoying that I Googled it and found out that it was the IE Enhanced Security Configuration that was causing this problem. So I switched it off and not it doesn't prompt me any more :-)

d9d38306-eb0c-45da-be9d-16ab5859b542|0|.0
You write some LINQ code to update your SQL tables like this below BUT it does not throw an exception and it does not Update the tables!
using (var db=new SomeDatabaseContext())
{
db.SomeTable
.Where(x=>ls.Contains(x.friendid))
.ToList()
.ForEach(a=>a.status=true);
db.SubmitChanges();
}
The reason why is because your Table does not have a Primary Key! You can update your DBML designer to have that Primary Key and you don't need to touch the actual SQL Server tables for this to work!
Best of Luck.
93761768-dfef-4197-847f-1f4cbbaf8541|0|.0
WITH q AS
(
SELECT TOP 1 *
FROM mytable
/* You may want to add ORDER BY here */
)
DELETE
FROM q
Note that
DELETE TOP (1)
FROM mytable
will also work, but, as stated in the documentation:
The rows referenced in the TOP expression used with INSERT, UPDATE, or DELETE are not arranged in any order.
Therefore, it's better to use WITH
and an ORDER BY
clause, which will let you specify more exactly which row you consider to be the first.
d239380d-723a-441d-9268-72886c20df00|0|.0
ALTER FUNCTION [dbo].[fnGetPipelineProductsCarried]
(
@GIS_PipelineMasterId INT,
@EnglishOrFrench NVARCHAR(20) = 'English'
)
RETURNS VARCHAR(1000)
AS
BEGIN
DECLARE @ReturnEnglish VARCHAR(1000) = ''
DECLARE @ReturnFrench VARCHAR(1000) = ''
DECLARE @ProductCarriedName NVARCHAR(255) = ''
DECLARE @ProductCarriedNameFrench NVARCHAR(255) = ''
DECLARE @TempTable TABLE (
PipelineName NVARCHAR(255),
ProductCarriedName NVARCHAR(255),
ProductCarriedNameFrench NVARCHAR(255),
SUBABC NVARCHAR(5),
PercentH2S DECIMAL(18,3),
GIS_ProductCarriedTypeId INT,
GIS_PipelineMasterId INT,
DummyID INT IDENTITY(1,1) NOT NULL
)
INSERT INTO @TempTable
SELECT DISTINCT
pm.PipelineName,
pct.ProductCarriedName,
pct.ProductCarriedNameFrench,
pspc.SUBABC,
pspc.PercentH2S,
pspc.GIS_ProductCarriedTypeId,
ps.GIS_PipelineMasterId
FROM ((GIS_PipelineSegment ps
INNER JOIN GIS_PipelineSegmentProductCarried pspc ON ps.GIS_PipelineSegmentId = pspc.GIS_PipelineSegmentId)
INNER JOIN GIS_PipelineMaster pm ON ps.GIS_PipelineMasterId = pm.GIS_PipelineMasterId)
INNER JOIN GIS_ProductCarriedType pct ON pspc.GIS_ProductCarriedTypeId = pct.GIS_ProductCarriedTypeId
WHERE pm.GIS_PipelineMasterId = @GIS_PipelineMasterId
ORDER BY pm.PipelineName,
pspc.SUBABC;
--Counters
DECLARE @count INT
DECLARE @count_max INT
SET @count = 1
SELECT @count_max = COUNT(DummyID) FROM @TempTable
WHILE(@count <= @count_max)
BEGIN
SELECT @ProductCarriedName = ProductCarriedName,
@ProductCarriedNameFrench = ProductCarriedNameFrench
FROM @TempTable
WHERE DummyID = @count
SET @ReturnEnglish = @ReturnEnglish + @ProductCarriedName + ', '
SET @ReturnFrench = @ReturnFrench + @ProductCarriedNameFrench + ', '
--Must Always be at the end of the Loop
SET @count = @count + 1
END
IF @EnglishOrFrench = 'English'
BEGIN
SET @ReturnEnglish = CASE @ReturnEnglish
WHEN NULL THEN NULL
ELSE (CASE LEN(@ReturnEnglish)
WHEN 0 THEN @ReturnEnglish
ELSE LEFT(@ReturnEnglish, LEN(@ReturnEnglish) - 1)
END )
END
RETURN @ReturnEnglish
END
ELSE
BEGIN
SET @ReturnFrench = CASE @ReturnFrench
WHEN NULL THEN NULL
ELSE (CASE LEN(@ReturnFrench)
WHEN 0 THEN @ReturnFrench
ELSE LEFT(@ReturnFrench, LEN(@ReturnFrench) - 1)
END )
END
RETURN @ReturnFrench
END
RETURN @ReturnEnglish
END
d529bbdd-8101-4b18-99eb-d27c9283b76f|0|.0
Error: TF400018: The local version table for the local workspace MY-PC;My User could not be opened. The workspace version table contains an unknown schema version.

Fix
Backup the folder first!
Click the box in "Workspace".
Click on "Workspaces".
Delete the workspace profile you're currently using
Re-connect to TFS open "Source Control"
b1b111a3-f059-4f5b-a3b4-926a8e480a01|0|.0
So I just wasted 2 1/2 hours tring to figure out the WHY the Tab ordering was not working on my Form (C# project Visual Studio 2010).
No matter what I did the order DID NOT CHANGE. There are all kinds of controls like Groupboxes, Panels with Controls inside Controls. No big deal. The View -> Tab Order feature made NO DIFFERENCE at all!!
The only way the tab Order worked was by actually updating the DESIGNER to order the Controls in the way I wanted! Like this...
this.pnlSubAbc.Controls.Add(this.lblProductA);
this.pnlSubAbc.Controls.Add(this.cboProductA);
this.pnlSubAbc.Controls.Add(this.lblProductAH2S);
this.pnlSubAbc.Controls.Add(this.txtProductAH2S);
this.pnlSubAbc.Controls.Add(this.lblProductB);
this.pnlSubAbc.Controls.Add(this.cboProductB);
this.pnlSubAbc.Controls.Add(this.lblProductBH2S);
this.pnlSubAbc.Controls.Add(this.txtProductBH2S);
this.pnlSubAbc.Controls.Add(this.lblProductC);
this.pnlSubAbc.Controls.Add(this.cboProductC);
this.pnlSubAbc.Controls.Add(this.lblProductCH2S);
this.pnlSubAbc.Controls.Add(this.txtProductCH2S);
this.pnlSubAbc.Location = new System.Drawing.Point(3, 344);
this.pnlSubAbc.Name = "pnlSubAbc";
this.pnlSubAbc.Size = new System.Drawing.Size(562, 212);
this.pnlSubAbc.TabIndex = 2;
this.pnlSubAbc.TabStop = false;
this.pnlSubAbc.Text = "Products Carried";
Hope this Helps someone else out there.
5af4912c-144f-4661-9526-8b163b2e8adb|0|.0
Issue: You are performing an Sharepoint upgrade (via PSConfig.exe as mentioned here for example) but got the error Message "Cannot open SPTimerV4 service on computer '.'." as seen below:
An error has occurred while validating the configuration settings.
An exception of type System.InvalidOperationException was thrown.
Additional exception information: Cannot open SPTimerV4 service on computer '.'.
Solution: Make sure you are running the Powershell with "Run as Administrator" even if the account you are using has local Admin rights.
7dd6f3cf-6f9a-4479-a884-6d04d1ea107f|0|.0