TODO:
You are migrating old code to the latest version of Entity Framework, and you no longer have the Detach() method. To fix, use the code below.
SOLUTION:
((IObjectContextAdapter)myModel).ObjectContext.Detach(myobject);
NOTES:
There are no notes on this topic.
TODO:
You try to insert a record using the Entity Framework and get the following error:
"Unable to update the entityset because it has a defining query and no <UpdateFunction> element exists in the <ModificationFunctionMapping> element to support the current operation"
SOLUTION:
Add a primary key to the table. Also make sure the Concurrency Mode of the Primary Key is set to "Fixed" (right click column, choose properties)
NOTES:
There are no notes on this topic.
TODO:
You run the SharePoint Products Configuration Wizard, and you receive the error "Internet Information Services Is Not Installed", even though you have IIS installed. the issue is the IIS 6 features are not installed, and are required.
SOLUTION:
Install IIS6 features, and your issue will go away.
NOTES:
There are no notes on this topic.
TODO:
You have a Telerik RadGrid and when you click on the Add button, you get the " Sys.ArgumentException: Value must not be null for Controls and Behaviors. Parameter name: element" error.
SOLUTION:
In my case I had the following structure:
Panel 1
FormGroup (a control we built)
Panel 2
RadGrid 1
I had AjaxSettings in my code behind for "Panel 1" and "FormGroup". Having AjaxSettings for the nested controls caused my issue. I removed the AjaxSetting for "FormGroup" and the issue went away
NOTES:
There are no notes on this topic.
TODO:
You make some changes the ASP.net controls on your form, and possible your JQuery. You run your application and you end up with "Error: Sys.ArgumentNullException: Value cannot be null."
SOLUTION:
95% of the time I have had this issue, the problem was that I removed a control, and its references in the .cs file, but forgot it in the JQuery. So in the JQuery I was doing a .hide() on the removed control which causes the cryptic error above. To debug I simply looked for each instance of $('#mycontrolxxxxxxx').hide(); and made sure that #mycontrolxxxxxxx actually still existed. Sure enough, I forgot to remove a JQuery line. Once I removed the rogue JQuery line, the issue went away.
NOTES:
There are no notes on this topic.
TODO:
In Visual Studio, you try to click on Security or other items, and you receive "Team Foundation Error: Login Failure: Unknown Username or Bad Password"
SOLUTION:
You need to start Visual Studio as your Domain User
start -> run > runas /netonly /user:my domain\myuser "C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\devenv.exe
NOTES:
There are no notes on this topic.
TODO:
Have you ever received "Could not access network location..." when you attempt to install an application on Windows runnin in VMWare?
There are 2 sections of registry keys that need to be inspected.
SOLUTION:
Navigate to these 2 keys, and look for entries that hve invalid settings. In my case the HKCU had an entry called "Personal", that had a path to \\vmware-host\shared folders\documents. Once I changed that to "c:\Documents and Settings\myusername" the issue went away.
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders
HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders
NOTES:
The new path will require you to change "myusername" to your proper user name.
TODO:
Have you ever had the dreaded "Error occurred in deployment step 'Activate Features': <nativehr>0x80070002</nativehr><nativestack></nativestack>" error when deploying an Event Receiver that targets a specific list?
SOLUTION:
In my case, this was caused by an invalid 'ListURL' setting in my elements.xml file. Be sure the 'Site URL' property of your project points to the site that the List resides. If this is pointed to the level above, the list will not be found, and you will get the error above. ListURL needs to be 'Lists/'{your list name} ex. List/Customers, thus you see why it is important for the Site URL to be set properly.
NOTES:
There are no notes on this topic.
TODO:
Have you ever wanted to check to see if an update or other error occurred in your stored procedure. To do so check the @@ERROR variable, if it is 0, then no errors occurred.
SOLUTION:
IF @@ERROR = 0
BEGIN
--return the id of the row inserted
SELECT @@ROWCOUNT As RowsAffected
END
ELSE
BEGIN
SELECT -1 As RowsAffected
END
NOTES:
In the example above, I did not care about the error code, which is why i chose to return -1 in the ELSE.