Call EWS from SharePoint 2013 SharePoint Hosted App (JavaScript) in Office 365
I am trying to call the exchange web service (EWS) of an exchange online server from a SharePoint hosted app. I am limited thus to the use of Javascript. During my call i am always getting an access denied error.
The body of the SOAP request is good since I have tested it using a client application, but I am not being able to get it to work via a jquery ajax call. I am sure that this is an authentification issue and I have no problem sending the credentials during
the call. I have added them in the header. This is what I have ended up doing but still no luck.
functionGetUnReadEmailCount() {
varsoapPacket = "<?xml version='1.0' encoding='utf-8'?>"+
"<soap:Envelope xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xmlns:xsd='http://www.w3.org/2001/XMLSchema' xmlns:soap='http://schemas.xmlsoap.org/soap/envelope/'xmlns:t='http://schemas.microsoft.com/exchange/services/2006/types'>"+
'<soap:Header>'+
'<wsse:Security>'+
'<wsse:UsernameToken>'+
'<wsse:Username>******</wsse:Username>'+
'<wsse:Password>******</wsse:Password>'+
'</wsse:UsernameToken>'+
'</wsse:Security>'+
'</soap:Header>'+
"<soap:Body>"+
"<FindItem xmlns='http://schemas.microsoft.com/exchange/services/2006/messages' xmlns:t='http://schemas.microsoft.com/exchange/services/2006/types'Traversal='Shallow'>"+
"<ItemShape>"+
"<t:BaseShape>IdOnly</t:BaseShape>"+
"</ItemShape>"+
"<IndexedPageItemView MaxEntriesReturned='50' Offset='0' BasePoint='Beginning' />"+
"<Restriction>"+
"<t:IsEqualTo>"+
"<t:FieldURI FieldURI='message:IsRead' />"+
"<t:FieldURIOrConstant>"+
"<t:Constant Value='false' />"+
"</t:FieldURIOrConstant>"+
"</t:IsEqualTo>"+
"</Restriction>"+
"<ParentFolderIds>"+
"<t:DistinguishedFolderId Id='inbox' />"+
"</ParentFolderIds>"+
"</FindItem>"+
"</soap:Body>"+
"</soap:Envelope>";
$.support.cors = true;
$.ajax({
url: "https://outlook.office365.com/EWS/Exchange.asmx",
type: "POST",
dataType: "xml",
data: soapPacket,
complete: processResult,
error: OnError,
contentType: "text/xml; charset=\"utf-8\""
Any help is highly appreciated.
Thanks.
Elie
Hi Elie,
Since this forum is discussing about Developing Apps for Office 2013, and your issue is more related about Exchange development. I will move this thread to the more related forum.
Reference:
https://social.msdn.microsoft.com/Forums/en-US/home?forum=exchangesvrdevelopment
Thanks for your understanding.
Best Regards,
Edward
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey.
Similar Messages
-
Creating a subsite in hostweb from sharepoint hosted App
Hello All,
While creating a subsite in host web from sharepoint app, i am getting error the in the below line of code
" this.NewWebsite = hostweb.get_webs().add(webCreateInfo);"..unable to get the property "get_webs";
My code is as below
$(document).ready(
function () {
var hostUrl = decodeURIComponent(getQueryStringParameter("SPHostUrl"));
currentcontext = new SP.ClientContext.get_current();
var hostcontext = new SP.AppContextSite(currentcontext, hostUrl);
var hostweb = hostcontext.get_web();
var currentcontext.load(hostweb, "Title");
var webCreateInfo = new SP.WebCreationInformation();
//set values
webCreateInfo.set_description("This site is created from CSOM");
webCreateInfo.set_language(1033);
webCreateInfo.set_title("My Title");
webCreateInfo.set_url("/myURL");
webCreateInfo.set_useSamePermissionsAsParentSite(true);
webCreateInfo.set_webTemplate("STS#0");
//add sub site
this.NewWebsite = hostweb.get_webs().add(webCreateInfo);
//Load and execute query
currentcontext.load(this.NewWebsite, 'ServerRelativeUrl', 'Created');
currentcontext.executeQueryAsync(Function.createDelegate(this, this.Success), Function.createDelegate(this, this.oncListQueryFailed));
function Success() {
alert(this.NewWebsite.get_serverRelativeUrl());
function oncListQueryFailed(sender, args) {
alert('Request failed. ' + args.get_message() + '\n' + args.get_stackTrace());
Any help will be appreciated
dfdHello Steve,
Thanks for the Reply
Following code helped me in creating the Subsite successfully in host web
Var hostWebUrl;
Var appWebUrl;
Var context;
Var newSubsite;
function () {
try
hostWebUrl = GetQueryString("SPHostUrl");
appWebUrl = GetQueryString ("SPAppWebUrl");
var layoutsRoot = hostWebUrl +
'/_layouts/15/';
$.getScript(layoutsRoot + "SP.Runtime.js",
function () {
$.getScript(layoutsRoot + "SP.js", CreateSubsite);});
catch(ex)
alert("message" + ex.message);
function GetQueryString (name) {
name = name.replace(/[\[]/,
"\\\[").replace(/[\]]/,
var regex =
new RegExp("[\\?&]"
+ name + "=([^&#]*)"),
results = regex.exec(location.search);
return results ==
null ?
"" : decodeURIComponent(results[1].replace(/\+/g,
// Function to create subsite
function CreateSubsite () {
context = new SP.ClientContext(appWebUrl);
var hostContext =
new SP.AppContextSite(context, hostWebUrl);
var webCreateInfo =
new SP.WebCreationInformation();
//set values
webCreateInfo.set_description("New Subsite Created");
webCreateInfo.set_language(1033);
webCreateInfo.set_title("NewSubSite");
webCreateInfo.set_url("SubsiteURL");
webCreateInfo.set_useSamePermissionsAsParentSite(true);
webCreateInfo.set_webTemplate("STS#0");
this.web = hostContext.get_web();
newSubsite = this.web.get_webs().add(webCreateInfo);
context.load(newSubsite);
context.executeQueryAsync(
Function.createDelegate(this,successHandler),Function.createDelegate(this,errorHandler));
function successHandler() {
alert("subsite created successfully");
function errorHandler(sender, args) {
alert("Could not complete cross-domain call: " + args.get_message());
Vishnu -
Issue with REST POST call: CopyTo in a SharePoint hosted App not working
Hi Community
I have been really struggling to get a cross domain copy to work both in an App or even using REST Tools such as Postman or Google Advanced REST Client.
Ok there are various blog posts by Scott G et al. that shows how you can post say in a single domain. Now that's fairly straight forward
in my case I took a .apsx page and added the following lines of code - Checkin - refresh and great the file gets copied via the document ready function
(document).ready(function () {
alert('ready!');
var src = "/appsdev/Shared Documents/SrcDoc.docx";
var dst = "/appsdev/Shared Documents/DestDocCopiedByRestTestASPXPage.docx";
jQuery.ajax({
type: "POST",
contentType: "application/json;odata=verbose",
headers: {
"accept": "application/json;odata=verbose",
"X-RequestDigest": jQuery("#__REQUESTDIGEST").val()
url: _spPageContextInfo.webAbsoluteUrl + "/_api/web/getfilebyserverrelativeurl('" + src + "')/copyto(strnewurl='" + dst + "',boverwrite=true)",
success: function (data, errorCode, errorMessage) {
alert('Success: copied the damn file');
var jsonObject = JSON.parse(data.body);
var jsonObjectText = JSON.stringify(jsonObject);
error: errorHandler
Now I make the call in my SharePoint hosted App and I simple can' t get this to work. Fiddler doesn't exactly help a lot
var src = "/appsdev/Shared Documents/SrcDoc.docx";
var dst = "/appsdev/Shared Documents/DestDocCopiedByMyApp.docx";
var urlWriteLocalFileDebug = appweburl +
"/_api/SP.AppContextSite(@target)/web/Getfilebyserverrelativeurl('" + src + "')/copyTo(strNewUrl='" + dst + "', bOverWrite=true)?@target='" + hostweburl + "'";
executor.executeAsync(
method: "POST",
contentType: "application/json;odata=verbose",
headers: {
"accept": "application/json;odata=verbose",
"X-RequestDigest": jQuery("#__REQUESTDIGEST").val()
url: urlWriteLocalFileDebug,
success: function (data, errorCode, errorMessage) {
alert('Success: copied the damn file');
var jsonObject = JSON.parse(data.body);
var jsonObjectText = JSON.stringify(jsonObject);
error: errorHandler
I can happily run a GET and see the properties of my file but POST no way. Curriously, when I try to run the same command for say Google Advanced Rest Client I get nowhere
Is this a new mensa test!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Freelance consultantHi
I have now tested against a trail Office 365 Developer site and I had to make a few adjustments
- change the url
- change the target to SharePoint Onlne
- change the url
I still wasn't happy so I created a new SharePoint Hosted app and pointed at the above developer site. I copied my CrossDomainExec.js and stripped all my code except my CopyItemInSameLIbrary method which hasn't changed since I created this post.
- changed the App Manifest permissions to Web -full Control ( was previously tenant)
I still got errors which is really painful as you don't even see the POST request in Fiddler
The URL used for my POST is as follows ( note host URL is fictitious)
"https://myapphell-547d8061d39e38.sharepoint.com/sites/appsdev/RESTTestSHA/_api/SP.AppContextSite(@target)/web/Getfilebyserverrelativeurl('/sites/appsdev/Shared Documents/SrcDoc.docx')/copyTo(strNewUrl='/sites/appsdev/Shared Documents/DestDoc.docx', bOverWrite=true)?@target='https://myapphell.sharepoint.com/sites/appsdev'" String
Ran the app a second time and now I see......Wow it WORKS!!!!!! ..Can't be true can it?
.... next I will switch the target url to my on prem farm to see if this still works so watch this space!
Daniel
Freelance consultant -
SharePoint hosted app error log
Hi,
I'd like to log the error in ULS log from sharepoint hosted app [Client side]. Is it possible, if yes, please let me know how to do it..
Balaji -Please click mark as answer if my reply solves your problem.Hi,
You could write informations to the "App Error Log".
Have a look at these links :
http://exxlence.com/2013/01/07/add-logging-to-your-sharepoint-app-using-logcustomapperror-method/
http://sp2013.blogspot.fr/2013/01/sharepoint-apps-logging.html
Regards
Gilles Martinez
Twitter
Blog
Please mark as helpful/answer if this resolved your post -
SharePoint Hosted App - Creating cascaded drop down on hosted web lists
Hi,
I have created an SharePoint Hosted App(Javascript Object Model) that creates lists on the host web.
I need to put some javascript into new and edit forms in order to create the cascaded drop down effect on 2 lookup fields.
Can you please give me some advise?
Regards,
MarianHope below article should help you
http://blog.pentalogic.net/2010/11/editing-the-sharepoint-list-item-menu-part-2-using-javascript/
http://www.getinthesky.com/2014/03/hide-text-field-sharepoint-form-using-jquery/
http://social.msdn.microsoft.com/Forums/sharepoint/en-US/030471b2-d19a-470f-9a9e-0fd8a229138b/how-do-i-create-a-new-item-form-that-allows-to-save-and-continue-editing?forum=sharepointcustomizationlegacy -
Cross Domain Call in SharePoint Hosted app.
Hi, I am very new in SharePoint 2013 App dev and want to understand when actually Cross domain calls are required and how we can achieve it.
Getting host web site title from a sharepoint hosted app needs a cross domain call?
My point of confusion is some places I have seen we have to load SPRequestExecutor for getting data from host web but I am able to get it using changing the context to host web and then getting the title without using SPRequestExecutor:
appContextSite = new SP.AppContextSite(ctx, spHostUrl);
Nweb = appContextSite.get_web();
//Nweb = ctx.get_web();
ctx.load(Nweb);
What is the difference between the two( using SPRequestExecutor and not using) and what places we need to use it and where we can get data without it ?
please help me to resolve this confusion.
ThanksHi vmishr11,
When you use SP.RequestExecutor, it will execute asynchronously to get data from host web. It will use like below:
var executor = new SP.RequestExecutor(appweburl);
executor.executeAsync(
url:
appweburl +
"/_api/web/lists/getbytitle('Announcements')/items",
method: "GET",
headers: { "Accept": "application/json; odata=verbose" },
success: successHandler,
error: errorHandler
For SP.AppContextSite, it will execute in order to get data.
Here is a detailed article for your reference:
How to: Access SharePoint 2013 data from apps using the cross-domain library
Best Regards
Zhengyu Guo
TechNet Community Support -
Hi I am facing the three questions below.
1. How to use default RTE in custom page in Sharepoint hosted app.
I saw the article of Rich text Editor (ribbon based) in a webpart in SharePoint 2013 and tried it. But it did not work well. I guess it needs code-behind setting, however sharepoint hosted app does not support code-behind.
Does anybody know how to do this?
2. In above case, I placed the below code on custom page and tried to get the field's value when submit button was clicked.
<SharePoint:InputFormTextBox ID="rftDefaultValue"
RichText="true"
RichTextMode="FullHtml" runat="server"
TextMode="MultiLine" Rows="5">
</SharePoint:InputFormTextBox>
In debugger, the returned value was 'undefined'.
var note = $('#hogehoge').val();
Is it possible to get the RTE value? If yes, please let me know how to do this.
3. I need to submit the RTE value using REST call.
In this
article in MSDN, the item creation sample treats single line text field. Does anybody know the sample for RTE?Hi,
According to your description, you might want to use Rich Text Editor control in your SharePoint hosted app.
First of all, I would suggest you post one question in one thread to make it easier to be discussed, which would also help you get a quick solution.
Though we can add this control into a SharePoint hosted app, however, as we can’t add code behind for it, plus with the potential compatibility issues in different
browsers, I would suggest you use other JavaScript Rich Text Editor plugins instead.
Two JavaScript Rich Text Editor plugins for your reference:
http://quilljs.com/
http://nicedit.com/
If you want to submit the value of Rich Text Editor control to a SharePoint list using REST call, since the content in the Multiple Line of Text column is wrapped
with nested HTML tags, the similar requirement would also be applied to the content to be submitted.
Here is a code snippet about how to update a Multiple Line of Text column for your reference:
updateListItem(_spPageContextInfo.webAbsoluteUrl, "List018", 1);
function updateListItem(siteUrl, listName, itemId)
var itemType = GetItemTypeForListName(listName);
var item = {
"__metadata": { "type": itemType },
"MultiTextEnhanced": "<div><a href='http://bing.com/'>Bing</a><br></p></div>",
"Title": "123"
$.ajax({
url: siteUrl + "/_api/web/lists/getbytitle('" + listName + "')/items(" + itemId + ")",
method: "GET",
headers: { "Accept": "application/json; odata=verbose" },
success: function (data) {
console.log(data);
$.ajax({
url: data.d.__metadata.uri,
type: "POST",
contentType: "application/json;odata=verbose",
data: JSON.stringify(item),
headers: {
"Accept": "application/json;odata=verbose",
"X-RequestDigest": $("#__REQUESTDIGEST").val(),
"X-HTTP-Method": "MERGE",
"If-Match": data.d.__metadata.etag
success: function (data) {
console.log(data);
error: function (data) {
console.log(data);
error: function (data) {
console.log(data);
// Getting the item type for the list
function GetItemTypeForListName(name)
return"SP.Data." + name.charAt(0).toUpperCase() + name.slice(1) + "ListItem";
Thanks
Patrick Liang
Forum 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]
Patrick Liang
TechNet Community Support -
Getting error while uploading multiple files in sharepoint hosted app in 2013 with REST API
Hi All,
In one of my tasks, I was struck with one issue, that is "While uploading multiple files into custom list with REST API".
Iam trying to upload multiple files in library with REST calls for an APP development, my issue is if i wants to upload 4 image at once its storing only
3 image file and further giving "Conflict" error". Below is the attached screenshot of exact error.
Error within screenshot are : status Code : 409
status Text :conflict
For this operation i am uploading different files as an attachment to an list item, below is the code used for uploading multiple files.
my code is
function PerformUpload(listName, fileName, listItem, fileData)
var urlOfAttachment="";
// var itemId = listItem.get_id();
urlOfAttachment = appWebUrl + "/_api/web/lists/GetByTitle('" + listName + "')/items(" + listItem + ")/AttachmentFiles/add(FileName='" + fileName + "')"
// use the request executor (cross domain library) to perform the upload
var reqExecutor = new SP.RequestExecutor(appWebUrl);
reqExecutor.executeAsync({
url: urlOfAttachment,
method: "POST",
headers: {
"Accept": "application/json; odata=verbose",
"X-RequestDigest": digest
contentType: "application/json;odata=verbose",
binaryStringRequestBody: true,
body: fileData,
success: function (x, y, z) {
alert("Success!");
error: function (x, y, z) {
alert(z);Hi,
THis is common issue if your file size exceeds
upload a document of size more than 1mb. worksss well for kb files.
https://social.technet.microsoft.com/Forums/office/en-US/b888ac78-eb4e-4653-b69d-1917c84cc777/getting-error-while-uploading-multiple-files-in-sharepoint-hosted-app-in-2013-with-rest-api?forum=sharepointdevelopment
or try the below method
https://social.technet.microsoft.com/Forums/office/en-US/40b0cb04-1fbb-4639-96f3-a95fe3bdbd78/upload-files-using-rest-api-in-sharepoint-2013?forum=sharepointdevelopment
Please remember to click 'Mark as Answer' on the answer if it helps you -
Permissions required to deploy an "SharePoint hosted App" using VS 2013
Hello,
I'm trying to deploy a SharePoint Hosted App to an OnPrem SP2013 server.
When i hit F5 (from VS 2013) i get the below error:
"Error occurred in deployment step 'Uninstall app for SharePoint': The local SharePoint server is not available. Check that the server is running and connected to the SharePoint farm."
I'm added to the Farm Administrators group, site collection admin and to the admin group of the box. But i do not have any db_Owner permissions the the config / content database.
Do I need DB Access to deploy the apps? Please advice.
Thanks,
Keerth
Keerth R>>Do I need DB Access to deploy the apps? Please
advice.
Yes, you need to have db_owner permissions for the account which you are using to deploy the apps.
http://www.sharepoint-journey.com/app-development-in-sharepoint.html
My Blog- http://www.sharepoint-journey.com|
If a post answers your question, please click Mark As Answer on that post and Vote as Helpful -
SharePoint 2013 Provider hosted App installation error
Hi All,
I am trying to install a provider hosted app in SharePoint 2013. Installation goes for about 15mins and get "Sorry, something went wrong
with adding the app. Click to retry."
Please find belw ULS details for Correlation ID:
Error when try to get access token when deploy AppInstanceId 7bcf1d9d-897a-48a1-b4f4-cd3120fd98a5 with AppPrincipalId i:0i.t|ms.sp.ext|[email protected]01b993b6. Exception=System.InvalidOperationException:
An unexpected error was returned from the delegation service. Error Code: 'invalid_client' Error Description: 'ACS65003: The clientId 'd12de581-316c-4224-b58b-e91ac2042150/www.SERVERNAME.DOMAIN.com@0d85160c-5899-44ca-acc8-db1501b993b6' is not a valid
service identity. Trace ID: 4a0c4974-94f4-4077-9a22-2ba5f0abb444 Correlation ID: 674d9839-686b-45f3-be46-31db4dc2a9d0 Timestamp: 2014-07-23 09:34:49Z'
at Microsoft.SharePoint.Administration.SPAzureAccessControlDelegationServiceClient.HandleUnexpectedError(SPAzureAccessControlDelegationServiceResponse delegationServiceResponse)
at Microsoft.SharePoint.ApplicationServices.SPApplicationContextAccessToken.GetResponseOrThrow[T](SPAzureAccessControlDelegationServiceClient delegationServiceClient, SPAzureAccessControlDelegationServiceResponse delegationServiceResponse)
at Microsoft.SharePoint.ApplicationServices.SPApplicationContextAccessToken.IssueApplicationContextAccessToken(SPServiceContext serviceContext, SPApplicationContextAccessTokenCreationParameters creationParameters)
at Microsoft.SharePoint.SPSecurityContext.SecurityTokenForApplicationContext(SPIdentityContext userIdentityContext, String applicationId, Uri applicationRealm, SPApplicationContextAccessTokenType applicationTokenType, SPApplicationDelegationConsentType
consentValue)
at Microsoft.SharePoint.SPServerToAppServerAccessTokenManager.GetAccessTokenForDeploymentTask(Guid siteId, SPUserToken userToken, String appPrincipalId)
at Microsoft.SharePoint.Lifecycle.SPAppPrincipalAccessTokenTask.<>c__DisplayClass1.<Deploy>b__0()
sudesh withanageHi sudesh,
According to your description, my understanding is that you encountered the error “An unexpected error was returned from the delegation service" when you try to add a SharePoint 2013 Provider hosted App.
As the error message says, the clientId 'd12de581-316c-4224-b58b-e91ac2042150/www.SERVERNAME.DOMAIN.com@0d85160c-5899-44ca-acc8-db1501b993b6' is not a valid service identity when your SharePoint try
to get access token via ACS. Is there any plans to develop a low trust mechanism for non-connected scenarios? i.e. low trust provider hosted apps with no external connection, like say for a Bank who lock down external access. Please follow the
steps as the blog to set development environment for SharePoint Low-Trust Apps:
http://blogs.msdn.com/b/besidethepoint/archive/2012/12/10/sharepoint-low-trust-apps-for-on-premises-deployments.aspx?PageIndex=1#comments
Best Regards,
Eric
Eric Tao
TechNet Community Support -
Report Viewer control in sharepoint 2013 provider hosted app
sharepointSite/_vti_bin/ReportServer
We are migrating sp 2010 site to SP 2013 provider hosted app. we are using Report viewer control (version 10.0.0) in .net application app server, And the reporting service is configured in sharepoint site and report is uploaded in the document
library. We are using claims based authentication
ReportViewer1.ServerReport.ReportServerUrl =
newUri("sharepointSite/_vti_bin/ReportServer");
ReportViewer1.ServerReport.ReportPath = @"sharepointSite/_vti_bin/ReportServer?sharepointSite/Reports/Report1.rdl";
and am getting an error
ReportServerException: For more information about this error navigate to the report server on the local server machine, or enable remote errors]
[ReportServerException: The user does not exist or is not unique.]
[ReportServerException: Report Server has encountered a SharePoint error. (rsSharePointError)]
Microsoft.Reporting.WebForms.ServerReportSoapProxy.OnSoapException(SoapException e) +82
Microsoft.Reporting.WebForms.Internal.Soap.ReportingServices2005.Execution.ProxyMethodInvocation.Execute(RSExecutionConnection connection, ProxyMethod`1 initialMethod,
ProxyMethod`1 retryMethod) +770
Microsoft.Reporting.WebForms.ServerReport.EnsureExecutionSession() +105
Microsoft.Reporting.WebForms.ServerReport.SetParameters(IEnumerable`1 parameters) +163
BP.SDC.eXPP.UIAppsWeb.UserControls.Baseline.ProgressDashboard.RefreshDashboardReport(Int32 userRoadMapDisciplineId, String roadmapSection)
System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3804
Can you please help me to solve this issueHi,
According to your post, my understanding is that you had issues about the provider hosted app.
Per the error, the issue may be related to the permission issue.
For a better troubleshooting, we can check with the following steps.
To norrow down the issue, please create a new and clean app to test whether it has the same issue.
You can check the ULS log to see if anything unexpected occurred when you deploy the app and open the site page.
For SharePoint 2013, by default, ULS log is at
C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\15\LOGS
You can check the ULS log by the methods here:
http://blogs.msdn.com/b/opal/archive/2009/12/22/uls-viewer-for-sharepoint-2010-troubleshooting.aspx
http://msdn.microsoft.com/en-us/library/gg193966(v=office.14).aspx
Thanks,
Jason
Forum 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]
Jason Guo
TechNet Community Support -
How to debug sharepoint 2013 provider hosted app?
We developed SharePoint 2013 provider hosted app using MVC 5 Entity Framework of Database first and publish in Windows Azure site as well as deployed that project to our SharePoint app Catalog. We need to change Windows azure site so we
changed to publish in another Windows Azure site and deployed again to our SharePoint app Catalog. No problem the app is working after we changed Windows Azure site. I am new of this technology I faced so hard of changed
existing Windows Azure site to New Windows Azure site. Please tell me how to debug the SharePoint Provider hosted app? Please tell me step by step process.
Thanks in Advance.Hi,
According to your description, you might want to know how to debug provider hosted app.
To get a quick start, I would suggest you take a look at the link below about
Debugging SharePoint Apps That Are Hosted In Windows Azure Web Sites:
http://blogs.technet.com/b/speschka/archive/2013/11/25/debugging-sharepoint-apps-that-are-hosted-in-windows-azure-web-sites.aspx
Another two similar articles for your reference:
http://sharepointfieldnotes.blogspot.jp/2013/03/making-it-easy-to-develop-and-debug.html
http://blogs.msdn.com/b/officeapps/archive/2013/01/03/debugging-remote-event-receivers-with-visual-studio.aspx
Best regards,
Patrick
Patrick Liang
TechNet Community Support -
Visual Studio 2013 problem during develop basic SharePoint-hosted app
Hi,
i am begginer in developing Sharepoint apps using Visual studio 2013.
I followed this instructions http://msdn.microsoft.com/en-us/library/fp142379.aspx for creating a basic SharePoint-hosted app.
When i tried to build my application (Step 10 in create and deploy your first Sharepoint-hosted app) i got the following error:
Error occurred in deployment step 'Install app for SharePoint': Sideloading of apps is not enabled on this site.
What is the problem?
thanks, Aphroditehttp://blogs.msdn.com/b/josrod/archive/2013/02/04/quot-sideloading-of-apps-is-not-enabled-on-this-site-quot.aspx
In order to publish a SharePoint hosted app to a site collection the site must be based on the developer site template or have the “Developer” Feature enabled on it. The “Developer” Feature is marked as hidden in its definition so you must use PowerShell
to enable the Feature.
Enable-SPFeature e374875e-06b6-11e0-b0fa-57f5dfd72085 –url
http://sp.contoso.com
Also check below:
http://blogs.msdn.com/b/officeapps/archive/2013/12/10/enable-app-sideloading-in-your-non-developer-site-collection.aspx
If this helped you resolve your issue, please mark it Answered -
How to open List when Page loads in SharePoint Hosted App?
I want to create an app same like InstantPracticeManager by InstantQuick.
Now I want to know that in a SharePoint Hosted App How can I show the Whole List in a page.
Here I have added one image:
Here there is one list and there are 4 views of that list.
Now the App will be like when I load the page It will show like the image above. Now how can we show the list like this in sharepoint hosted app?
I want the same scenario which is shown in the following blogs:
http://sp2013.blogspot.in/2012/08/use-list-view-in-sharepoint-2013-apps.html
and
http://www.sharepointnutsandbolts.com/2013/08/working-with-web-parts-within.html
where they add a list to an app
Can any one suggest me the idea? I am bit confused.
thanks in advance.Hi,
According to your post, my understanding is that you want to show the different list view in a page in SharePoint Hosted App.
We can use jQuery and cross-domain library to achieve it.
The following articles for your reference:
Adding a Tabbed View to A Web Part Page Using jQueryUI
http://sympmarc.com/2011/11/09/adding-a-tabbed-view-to-a-web-part-page-using-jqueryui/
How to: Access SharePoint 2013 data from apps using the cross-domain library
http://msdn.microsoft.com/en-us/library/office/fp179927(v=office.15).aspx
SharePoint 2013: Get list items by using the cross-domain library (JSOM)
http://code.msdn.microsoft.com/office/SharePoint-2013-Get-items-d48150ae/view/SourceCode#content
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 -
Hi All,
I have SharePoint hosted app deployed on On-Premise using(F5) which reads User Profile data consumes WCF(Hosted on same server) through REST API to insert data in to SQL DB(Different server).
SharePoint hosted app was working as expected and suddenly it started asking for credential and not login(any user) to the application landing page.
Checked SharePoint Logs, IIS Logs and Windows log but did not get any clue.
WCF is accessible, User Profile access is also happening but not sure what changes done on server or infra level which causing this issue.
I have an On-Premise Environment for SharePoint 2013. where we have created SharePoint hosted app which calls "http:///_api/SP.UserProfiles.PeopleManager/GetMyProperties" to get current user's data. but this gives me 401 unauthorized error.
Notes:
I had given read permission to user profile and full control to sitecollection in appmanifest. If I run this app on Office 365 developer site it works fine, but on premise environment it give 401 error.
On premise environment when I deploy this app 3 times it prompt for credential and finally gives the following error
Error message after login 3 times:
{"error":{"code":"-2147024891, System.UnauthorizedAccessException","message":{"lang":"en-US","value":"Access
denied. You do not have permission to perform this action or access this resource."}}}
-Lovekush KumarAdd your site (http://*.app.contoso.com) to your local intranet sites in IE.
"app.contoso.com" is app domain.
My Blog- http://www.sharepoint-journey.com|
If a post answers your question, please click Mark As Answer on that post and Vote as Helpful
Maybe you are looking for
-
Application Migration from JBOSS to Weblogic Server
Hi, I am facing lots of issues while deploying an .ear file on Weblogic server. In the JBOSS server the application is working properly but whenever I am trying to deploy it on Weblogic server its throwing me an error stating : "ERROR: No j2ee module
-
Error assigning users to application Role in Obiee 11.1.1.7.0
Hello I installed Obiee 11.1.1.7.0 both on Windows and Linux platform and after that, I successfully set Active Directory integration. I have a problem assigning users to Application Role in EM. When I'm trying to search a user on Display name, the P
-
Document Distribution order package status IW?
Hi I am working on document distribution. the workflow is starting very well but fails to proceed at the status <b>IW</b>. On top of the order staus, there is a message "Not assigned to distr. order package". I am failing to troubleshoot it. Any idea
-
WebUtil questions...
Hi, I'm using WebUtil to have user upload the file from their computers to server, but the file on the server got the date they're uploaded, not the original date they've been created, is there any way I can set it up to keep the original file date?
-
HI Gentlemen, I have to run my report twice, once with 'Original' and once with 'Copy' in the top margin. It works fine if I execute it twice, supplying a text parameter from outside. However, this generates two PDF files. This is undesirable--they s