Chapter 4 - The Local SharePoint Server is not available
Ok, grinding through the exercises to the point where I have a running SP2013 on a VM on my machine. The development site is provisioned and running, but Visual Studio 2012 (also installed on the VM) cannot validate the URL. I get the message: "The local SharePoint server is not available. Check that the server is running and connected to the SharePoint farm". However, when I use the URL it works. This may have more to do with permissions since I have to run VS as administrator. That said, I tried adding administrator as a member of the owners group. It still doesn't work. Perhaps a database access issue? Any thoughts? Has anyone else successfully created and run the Visual Web Part in Chapter 4?
... (a couple of hours later)
So, it was a permissions issue. I had to add myself to the SA group in the database. Also, the steps to complete the exercise are wrong and the reference to default.aspx should be MyNewVisualWebPart.ascx (similarly for the corresponding cs file). With that done, everything appears to publish correctly, but I can't find the Web Part on the site. As such, I can't insert it onto a page so I still have some more work. I suppose this should be easier, but I guess that all of this extra effort is helping me to gain some valuable insights.
... (many days later)
I am finally able to find the 'custom' option to insert my new web part onto the page. However, after doing so, the web part did not work. This is easily remedied by adding onclick="lnkGetSalesData_Click" to the asp LinkButton control. After all of this, I finally have my web part working. Hopefully this will help those that follow. Now on to the next example ...
Last edited by smurphy; August 21st, 2013 at 01:49 PM.