Symptoms
I am using K2 for Visual Studio.
I am trying to set the "Connection Settings" in the "K2 for SharePoint Process Wizard". When I selected a SharePoint Site URL, then tried to select a site, the list of the sites displayed deleted sites. (I created a site called "SmartFormsDeletionTest", then deleted it and re-created a list with the same name twice. So, the first two lists have been deleted, and there is one list called "SmartFormsDeletionTest" exist now.)
The deleted sites have been completely deleted not only from the SharePoint recycle bin but also from the parent site. So these sites no longer exist in SharePoint completely.
Still, the K2 connection settings displays these deleted sites.
Diagnoses
If SP list is removed from SP site without deleting K2 artifacts, then K2 artifacts (i.e. smartobjects, forms/views) still exist.
Resolution
Lets say that I deleted the ‘1’ SP list WITHOUT deleting the K2 for SharePoint artifacts on the list. I would end up with duplicate lists after recreating the ‘1’ List and adding the K2 app again.
Navigate to the ‘1’ List again on SP and click the K2 Application again. It will navigate me to the artifact page, and I can get the List GUID from the link.
Make a BACKUP of the K2 database first.
-Run this query and filter on the ListDisplayName.
Use K2
SELECT *
FROM CK2].bIntegration]..ProcessSharePointSetting] where ListDisplayName like '%1%'
I should be able to delete the ‘1’ List with ID starting with A0BA.
Stop K2 blackpearl Server service
Delete from >K2]./Integration].[ProcessSharePointSetting] where ListID = 'MyGUID'
After deleting the orphan list, close the K2 for VS and re-launch it. You should be able to see the update.