HTML client & Sharepoint 2013

When I change Sharepoint settings in the project from one Sharepoint server to another, I always get the message 
Value cannot be null.
Parameter name: sharePointHostData
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.ArgumentNullException: Value cannot be null.
Parameter name: sharePointHostData
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[ArgumentNullException: Value cannot be null.
Parameter name: sharePointHostData]
Microsoft.LightSwitch.Framework.Server.SharePointHost..ctor(SharePointAuthDataBase sharePointHostData) +97
Microsoft.LightSwitch.Framework.Server.SharePointApplication`3.get_SharePoint() +85
Microsoft.LightSwitch.Framework.Server.SharePointLaunchBase.Page_Load(Object sender, EventArgs e) +162
System.Web.UI.Control.OnLoad(EventArgs e) +92
System.Web.UI.Control.LoadRecursive() +54
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +772
when I start solution with F5 from Visual studio. Can anyone have an idea why?
Connecting to dev site directly on that sharepoint server is fine, but when I want to use it for debug....error.
Thanks!

To troubleshoot this issue, you need follow the blog above to configure your SharePoint first.
Moreover, here are some suggestions for you.
1. To create an app for SharePoint, you enable the SharePoint features in LightSwitch. 
Reference:
Enable an application for SharePoint
2. Deploy A LightSwitch Application To Office 365
/ SharePoint Online

Similar Messages

  • HTML Client: How to get the content/value of a custom control?

    I made two Custom Controls named, "CustomControl_1" and "CustomControl_2". 
    In the render function of "CustomControl_1", how to access the value of "CustomControl_2"?
    For example,
    myapp.BrowseOrders.CustomControl_2_render = function (element, contentItem) {
    $(element).text("Some Value");
    myapp.BrowseOrders.CustomControl_1_render = function (element, contentItem) {
    $(element).text( Value of CustomControl_2 ? );

    I would recommend creating screen properties and binding the controls to those screen properties. Then you can easily get a reference to any value. See this article for an example of the process using custom controls:
    Using The Clippy Agent in the Visual
    Studio LightSwitch HTML Client
    Unleash the Power - Get the LightSwitch 2013 HTML Client / SharePoint 2013 book
    http://LightSwitchHelpWebsite.com

  • How can I wait till data is loaded and get the latest entities in HTML CLient

    This is my first try using a JavaScript component. I found a nice timeline-Scheduler on github:
    Timeline Javascript Scheduler
    I made an nearly empt new Screen and I am using LS only to get the data and to switch to the next date.
    This works fine for the first date I set in the created.
    But if I change to the next day, there are still the just loaded records. When I switch again to the following date I get the records from the day before...
    myapp.dispo.divcontainer_render = function (element, contentItem) {
    // We need this div for the timeline
    $(element).append('<div class="calendar"></div><div class="realtime-info"></div>');
    //Bind to the date
    contentItem.dataBind("screen.suchDispodat", function (value) {
    var querydat = value;
    var items = [];
    var sections = [];
    //The querydat is set to the right date but the records I get are from the last executed query.
    contentItem.screen.getQuerydispobydatfahrerorderfahrer(querydat).then(function (result) {
    var dispos = result.data;
    dispos.forEach(function (dispo) {
    How can I bind the refresh to something like data loaded?
    Helmut

    From:
    http://blogs.msdn.com/b/lightswitch/archive/2012/12/19/enhancing-lightswitch-controls-with-jquery-mobile-michael-zlatkovsky.aspx
    "You could use setTimeout (which is sometimes necessary – see Joe’s Custom Controls post
    for an example)"
    Unleash the Power - Get the LightSwitch 2013 HTML Client / SharePoint 2013 book
    http://LightSwitchHelpWebsite.com

  • SSRS reports from Lightswitch Html Client

    I have created a Lightswitch desktop application that list the available reports that are stored in a table and also provides a button that when clicked launches the web browser to the URL for the report on the SQL server. My problem is now I'm trying to
    create the HTML client for the application and have no experience with Java Script. Does anyone know how to accomplish the something that I did on the desktop application on the HTML client?
    Below is the code that I used to open the URL in the browser in the desktop application.
    Imports Microsoft.LightSwitch.Threading
    Imports System.Runtime.InteropServices.Automation
    Namespace LightSwitchApplication
    Public Class ListReports
    Private Sub RunReport_Execute()
    ' Write your code here.
    Dim uri As New Uri(ReportsSet.SelectedItem.ReportAddress) 'website stored in the ReportsSet.ReportAddress field
    If (AutomationFactory.IsAvailable) Then
    Dim shell = AutomationFactory.CreateObject("Shell.Application")
    shell.ShellExecute(uri.ToString)
    ElseIf (Not System.Windows.Application.Current.IsRunningOutOfBrowser) Then
    System.Windows.Browser.HtmlPage.Window.Navigate(uri, "_blank")
    End If
    End Sub
    End Class
    End Namespace

    This may help:
    Creating Reports in LightSwitch HTML Client
    // Show Loading message
    var LoadingDiv = $("<div></div>");
    var Loading = $("<h1>&nbsp;&nbsp;&nbsp;&nbsp;Loading Report...</h1>");
    Loading.appendTo(LoadingDiv);
    LoadingDiv.appendTo($(element));
    // Get Report
    var HTMLContent = $("<div></div>").html(
    "<object width='650px' height='650px' data='../reports/ReportViewer.aspx?SurveyId="
    + contentItem.screen.SurveyId + "'/>"
    // Make report appear on top of the Loading message
    HTMLContent.css({
    "margin-top": "-50px"
    HTMLContent.appendTo($(element));
    Unleash the Power - Get the LightSwitch 2013 HTML Client / SharePoint 2013 book
    http://LightSwitchHelpWebsite.com

  • Problem with accessing parameter in HTML client, Access is not possible before created.

    I have one Screen in which I set a date.
    I pass the date to another Screen. In this screen I have a tile list showing all the busses and I want to show the current number of orders of the passed date for each bus.
    So I created a custom field in the tile for showing the amount of orders,  and it workes fine for a hardcoded date.
    But I have no access to the passed parameter, because it is to early.
    I get access after Screen.created to the Parameter, but there it is too late, because the list is already created with 0 as order Count.
    myapp.freieBusse.bkz1_render = function (element, contentItem) {
    var querybus = contentItem.value;
    // var querydatum = new Date(); <=== This works fine for today
    var querydatum = screen.queryDatumScreen; <== queryDatumScreen = Null at this Moment.
    myapp.activeDataWorkspace.wksqlData.QueryDispoByDatAndBus(querybus,querydatum).execute().then(function (results) {
    var countDispo = CountDispo(results);
    element.innerHTML = countDispo;
    function CountDispo(disposaetze) {
    var totalDisp = 0;
    var dispos = disposaetze.results;
    dispos.forEach(function (dispo) {
    totalDisp = totalDisp + 1;
    return totalDisp;
    How can I get an eralier Access to the Parameter. Or how can I manipulate the order Count of each row in the created of the Screen?
    Helmut

    The result is as slow that you can count the order with your fingers, but it works.
    If you use a
    WCF RIA Service the result will be fast. The calculations are performed inside SQL server and returned to the LightSwitch client in a single call per page.
    You can also use a Web API call but for a table of data it actually takes a lot of careful JavaScript code and you lose the drag and drop and strong typing in the HTML designer.
    Unleash the Power - Get the LightSwitch 2013 HTML Client / SharePoint 2013 book
    http://LightSwitchHelpWebsite.com

  • LightSwitch is not showing related data - HTML Client

    The AddEdit screen doesn't display any related data, but if I press the Save button without making any changes, close the screen & reopen it, it then shows the data just for that particular record. 
    For example I have an Employee entity & it has a GenderID(foreign key)  which is coming from Gender table. When I open the Employee’s Add/Edit screen the Gender appears blank. If I hit the Save button without doing any data changes, close the screen
    & reopen it & it then shows the Gender correctly.
    Fiddler shows it is querying correctly & also getting the response, but somehow it
    doesn’t appear on the screen. I’ve checked the Add/Edit screen of other entities & it seems the problem is specific to this one only.  I’ve also created a new Add/Edit screen for the same entity & it has the same problem.
    Divyang Vyas

    Manage include data may help:
    LightSwitch Tips & Tricks on Query Performance
    Unleash the Power - Get the LightSwitch 2013 HTML Client / SharePoint 2013 book
    http://LightSwitchHelpWebsite.com

  • Asynchronous visual webpart for SharePoint 2013

    HI,
    How to create asynchronous visual webparts in SharePoint 2013 (VS 2012) . I can see lot of examples for 2010 version, but not for SP 2013.
    I have 2 visual webparts, which I want to make it as a asynchronous webpart. One webpart has the code written in Javascript client object model(loads lot of images), another is a server side webpart which has a SPGridview.
    Is there any sample code available for SP 2013?
    Thanks

    Hi,
    Please try to convert the SharePoint 2010 project to SharePoint 2013.
    http://sadomovalex.blogspot.kr/2013/02/convert-visual-studio-sharepoint-2010.html
    In SharePoint 2013, we can create a visual web part, then we can use jQuery Ajax and REST API to achieve asynchronous data loading.
    More information:
    http://www.dotnetcurry.com/showarticle.aspx?ID=1009
    http://asyncwebpartframewrk.codeplex.com/releases/view/52459
    Thanks,
    Dennis Guo
    TechNet Community Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected]
    Dennis Guo
    TechNet Community Support

  • SharePoint 2013 - Unable to open Office documents in Internet Explorer - cannot access file

    In SharePoint 2013 some of our users receive an error message when trying to open an Office application from Internet Explorer 11.  Other users on the same browser don't have this issue. 
    Any ideas on how to resolve?

    HI Greg,IE11 is having some issues with the SharePoint 2013.
    http://expertsharepoint.blogspot.de/2014/08/issues-with-sharepoint-2013-and.html
    Since
    SharePoint 2013 fully support IE 32-bit version above 7, there might be compatibility issue with other browsers. I’d recommend you use IE 8,9,10 32-bit for optimal
    Performance.
    3.   
    Make sure the IE (Internet Explorer) Version should be 32-bit and not
    a 64-bit
    - See more at: http://expertsharepoint.blogspot.de/search/label/Known%20Issues?updated-max=2014-08-19T17:33:00%2B08:00&max-results=20&start=4&by-date=false#sthash.a2N14nDL.dpuf
    Anil Avula[MCP,MCSE,MCSA,MCTS,MCITP,MCSM] See Me At: http://expertsharepoint.blogspot.de/

  • SharePoint 2013 Client Side Object Model Javascript

    Hi,
    I am using Javascript Client Object Model in SharePoint 2013. What i am trying to do is:
    retrieve items from a particular list which exist on an another site collection. However, the Items that I want to retrieve will be based on particular value in the current site's list where I am writing the script.
    So for eg: I have a sharePoint list called "project status" in site A with project name (hyperlink URL field)  and project status as Managed metadata fields as two fields.
    I have site B where I have  "projects" list with Project name as the URL field. what I want to do is compare the project URL name in Projects list in site B to the Project name  URL in Project status list in Site A and retrieve the status
    so I can do a dashboard in site B using the same status in Site A

    Hi Cooltechie1234,
    You can filter the list item using CAML Query firstly and then set the managed metadata field label using JavaScript Client Object Model.
    If you have trouble in CAML Query, I suggest you can use CAML Designer to figure it out.
    More reference:
    http://cann0nf0dder.wordpress.com/2013/04/10/search-caml-query-with-managed-metadata/
    http://sharepoint.stackexchange.com/questions/113146/how-do-you-properly-write-to-a-managed-metadata-column-from-jsom-sharepoint-20
    http://www.vrdmn.com/2012/12/working-with-taxonomy-and-javascript-in.html
    Best Regards
    Zhengyu Guo
    TechNet Community Support

  • How to create a Document Set in SharePoint 2013 using JavaScript Client Side Object Model (JSOM)?

    Hi,
    The requirement is to create ""Document Sets in Bulk" using JSOM. I am using the following posts:-
    http://blogs.msdn.com/b/mittals/archive/2013/04/03/how-to-create-a-document-set-in-sharepoint-2013-using-javascript-client-side-object-model-jsom.aspx
    http://social.msdn.microsoft.com/Forums/sharepoint/en-US/1904cddb-850c-4425-8205-998bfaad07d7/create-document-set-using-ecma-script
    But, when I am executing the code, I am getting error "Cannot read property 'DocumentSet' of undefined "..Please find
    below my code. I am using Content editor web part and attached my JS file with that :-
    <div>
    <label>Enter the DocumentSet Name <input type="text" id="txtGetDocumentSetName" name="DocumentSetname"/> </label> </br>
    <input type="button" id="btncreate" name="bcreateDocumentSet" value="Create Document Set" onclick="javascript:CreateDocumentSet()"/>
    </div>
    <script type="text/javascript" src="//ajax.aspnetcdn.com/ajax/jQuery/jquery-1.7.2.min.js"> </script>
    <script type="text/javascript">
       SP.SOD.executeFunc('sp.js','SP.ClientContext','SP.DocumentSet','SP.DocumentManagement.js',CreateDocumentSet);
    // This function is called on click of the “Create Document Set” button. 
    var ctx;
    var parentFolder;
    var newDocSetName;
    var docsetContentType;
    function CreateDocumentSet() {
        alert("In ClientContext");
        var ctx = SP.ClientContext.get_current(); 
        newDocSetName = $('#txtGetDocumentSetName').val(); 
        var docSetContentTypeID = "0x0120D520";
        alert("docSetContentTypeID:=" + docSetContentTypeID);
        var web = ctx.get_web(); 
        var list = web.get_lists().getByTitle('Current Documents'); 
        ctx.load(list);
        alert("List Loaded !!");
        parentFolder = list.get_rootFolder(); 
        ctx.load(parentFolder);
        docsetContentType = web.get_contentTypes().getById(docSetContentTypeID); 
        ctx.load(docsetContentType);
        alert("docsetContentType Loaded !!");
        ctx.executeQueryAsync(onRequestSuccess, onRequestFail);
    function onRequestSuccess() {       
        alert("In Success");
        SP.DocumentSet.DocumentSet.create(ctx, parentFolder, newDocSetName, docsetContentType.get_id());
        alert('Document Set creation successful');
    // This function runs if the executeQueryAsync call fails.
    function onRequestFail(sender, args) {
        alert("Document Set creation failed" + + args.get_message());
    Please help !!
    Vipul Jain

    Hello,
    I have already tried your solution, however in that case I get the error - "UncaughtSys.ArgumentNullException: Sys.ArgumentNullException:
    Value cannot be null.Parameter name: context"...
    Also, I tried removing SP.SOD.executeFunc
    from my code, but no success :(
    Kindly suggest !!!
    Vipul Jain

  • Unable to get the SharePoint 2013 List names using Client object model for the input URL

    Please can you help with this issue.
    We are not able to get the SharePoint 2013 List names using Client object model for the input URL.
    What we need is to use default credentials to authenticate user to get only those list which he has access to.
    clientContext.Credentials = Net.CredentialCache.DefaultCredentials
    But in this case we are getting error saying ‘The remote server returned an error: (401) Unauthorized.’
    Instead of passing Default Credentials, if we pass the User credentials using:
    clientContext.Credentials = New Net.NetworkCredential("Administrator", "password", "contoso")
    It authenticates the user and works fine. Since we are developing a web part, it would not be possible to pass the user credentials. Also, the sample source code works perfectly fine on the SharePoint 2010 environment. We need to get the same functionality
    working for SharePoint 2013.
    We are also facing the same issue while authenticating PSI(Project Server Interface) Web services for Project Server 2013.
    Can you please let us know how we can overcome the above issue? Please let us know if you need any further information from our end on the same.
    Sample code is here: http://www.projectsolution.com/Data/Support/MS/SharePointTestApplication.zip
    Regards, PJ Mistry (Email: [email protected] | Web: http://www.projectsolution.co.uk | Blog: EPMGuy.com)

    Hi Mistry,
    I sure that CSOM will authenticate without passing the
    "clientContext.Credentials = Net.CredentialCache.DefaultCredentials" by default. It will take the current login user credentials by default. For more details about the CSOM operations refer the below link.
    http://msdn.microsoft.com/en-us/library/office/fp179912.aspx
    -- Vadivelu B Life with SharePoint

  • Connecting a SharePoint 2013 Document Library to Outlook 2010 client

    Good Day,
    Can someone please confirm if you can connect a SharePoint 2013 Document Library to Outlook 2010 client?
    I have seen articles, like the one shown below for Outlook 2013 to SharePoint 2013;
    http://www.sharepointgeoff.com/how-to-connect-a-sharepoint-2013-document-library-to-outlook-2013/
    Please provide a link to documentation to validate what Outlook Office versions will support viewing Document Library from Outlook client from a SharePoint 2013 Document Library.
    Thanks in advance for taking the time to review my request.
    Regards,
    Mark

    Hi Mark,
    Per my understanding, you might want to connect SharePoint 2013 Document Library to Outlook 2010 client application.
    Yes, SharePoint 2013 Document Library can connect to Outlook 2010 client application, the connecting process is similar as what SharePoint 2013 connect to Outlook
    2013 client application does.
    Thanks
    TechNet Community Support
    Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact
    [email protected]

  • SharePoint 2013 Document Library template displays html code when creating a new document from a sharepoint list multiline rich text

    I have a 2010 work flow that is associated with a sharepoint 2013 list that creates a new list document using a custom Microsoft Word 2013 template with a rich text multiline field quick part.  The workflow creates the document and populates
    the the quickpart, however, the text in the document is showing html codes
    <div class="ExternalClass2116495984EB429D95B02CC15F85FD4C"><h1>ABC123</h1><h2>Test&#58; 1234</h2></div>
    and not as 
    ABC123
    Test: 1234
    Is there a no code solution for this?

    Hi,
    I have done a test and I can reproduced your issue.
    I referred to the blog about Automatically create Word documents which include list fields:
    http://blogs.technet.com/b/brenclarke/archive/2009/04/15/automatically-create-word-documents-which-include-list-fields.aspx
    When I create a multiple line of text column in a list, I just choose Plain text, Then I solved the issue:
    Besides, here is a similar post, you can take a look at:
    https://social.technet.microsoft.com/Forums/sharepoint/en-US/a7ab3a61-6643-4a47-a464-fe46b5db1558/rich-text-field-showing-html-code
    Best Regards,
    Lisa Chen
    Lisa Chen
    TechNet Community Support

  • Sharepoint 2013 client object model FQL

    Hi,
    Im using Sharepoint 2013 client object model api and im trying to search on sharepoint by using FQL, but I dont get any results when Im using FQL, but when Im trying similar KQL syntax I get results.
    I''ve heard that I need to enable the FQL but I can't find how, In 2010 api its a proeprty in KeywordQuery class.
    code:
    KeywordQuery keyword = new KeywordQuery(client);
    // KQL
    keyword.QueryText = "title:mon*";
    // FQL
    keyword.QueryText = "starts-with(title:string("mon"))";
    Thank you

    To enable FQL, you have to copy the default result source and modify the Query Transformation string {?{searchTerms} -ContentClass=urn:content-class:SPSPeople}, at one of these
    levels -- Search Service Application (SSA), Site Collection, or Site -- and in one of the following ways:
    Remove the KQL filter, -ContentClass:urn:content-class:SPSPeople, from the Query Transformation. The resulting Query Transformation string will be: {?{searchTerms}}
    Replace the Query Transformation string with an FQL equivalent, such as {?andnot({searchTerms},filter(contentclass:"urn:content-class:SPSPeople*"))}.
    Source :http://msdn.microsoft.com/en-us/library/office/jj163973.aspx
    Bala

  • Advantages and Disadvantages of Client Object Model in sharepoint 2013

    I need Advantages and Disadvantages of Client Object Model in sharepoint 2013
    like below in javascript. Users will have read/edit and approve access to the list.
      var clientContext = new SP.ClientContext.get_current();
           var oList = clientContext.get_web().get_lists().getByTitle('Workflow Tasks');
    MCTS Sharepoint 2010, MCAD dotnet, MCPDEA, SharePoint Lead

    Thanks 
    AlexanderShelopukho for
    right answer!
    Alex-
    I do not need comparison- 
    I need Advantages and Disadvantages of Client Object Model in sharepoint 2013
    MCTS Sharepoint 2010, MCAD dotnet, MCPDEA, SharePoint Lead

Maybe you are looking for

  • ITunes no longer opens in XP

    This problem just started a few days ago. Up until then, I was using iTunes with no problems. I have a Dell Dimension 3000 running Windows XP. (Yes, I know I need to upgrade, but the program was running fine until just recently.) There were no system

  • InDesign cs6 spell check and master pages

    I have created a set of master pages for a template in InDesign cs6. When I create a document from this template and apply "spelling", the spell check goes through every master page before moving to the document. How can I stop spell check from going

  • Getting SOAPExceptionImpl while invoking JAX-RPC Service

    Hi, I am using Static Stub to invoke a service . Both the Client and and Service are deployed on same Tomcat. Service is quite simple that display the Greeting message but when I am calling a service it throws the following exception.. java.rmi.Remot

  • Archive process hung on all cisco devices - help

    I have Archive setup on all of my devices in the enviornment to archive configs via tftp to a server on the network.  A team mate of mine elected to down that box because the "did no know what it was."  Now I have a process hung on every one of my ci

  • Create project task

    Hi, I wanted to know if there is an API to insert project tasks through pl/sql or we can do it through base tables directly. My requirement assumes inserting task for an existing project. Through my research, I came to find the api as pa_project_pub.