Adding new lines to “mailto:” link’s body

Suppose you need to create a mailto-link with subject and body but the body should contain few lines of a blank text right after staring text and before ending text, like on this screenshot:
<screenshot>
Let’s compile the link:
“mailto:email@domain.com
?

subject=Subject  *here we can also use URLencode  – %3Project name%3E appears to be <Project name>
&

body=Body,%3Cyour text%3E%0A%0D%0A%0D%0A%0D%0A%0D%3Cyour text%3E”
Here URLencode is also coming for help.
LF (line feed) can be encoded as %0A, and CR (carriage return) – as  %0D, allowing to create few blank lines betweent text.

Adding new lines to “mailto:” link’s body

Include ps1 scripts in other scripts

include in a different PS1 file, and then “dot source” that file to include it in the current scope:

. D:\script_common\MyCode.ps1

then launch functions from script above
or

To write your own modules in Powershell, you name the module with a .psm1 extension. Typically, you don’t do free floating code in one of these; you write functions which are then available to the code which imports the module.

To import a script module from anywhere, use the full path:

Import-Module D:\script_common\MyModule.psm1

Include ps1 scripts in other scripts

SharePoint provider hosted apps errors

SharePoint high-trust add-in, provider-hosted

Possible errors in ULS log:

#
SPApplicationAuthenticationModule: Failed to authenticate request, unknown error. Exception details: System.IdentityModel.Tokens.SecurityTokenException: The issuer of the token is not a trusted issuer.
Application error when access /_api/search/query, Error=The issuer of the token is not a trusted issuer.

#
Check for certificate (TrustedRootAuthority)
Check for correct usage og ClientId and IssuerId on add-in side (registration, New-SPTrustedSecurityTokenIssuer) and the opposite side – when creating JWT token and signing it
#
Application error when access /_api/search/postquery, Error=3001002;reason=The incoming identity is not mapped to any user profile account in SharePoint. Possible cause is that no user profiles are created in user profile database. Contact your administrator.

#
Check UserProfileService for user profile existence (in case the code uses not app-only mechanism, and involves user)

 

 

#

06/21/2016 17:02:26.68 w3wp.exe (0x2FD0) 0x01F8 SharePoint Foundation Claims Authentication 8306 Critical An exception occurred when trying to issue security token: Operation is not valid due to the current state of the object.. 1c57889d-7fb0-d015-1370-d106e146439d

#

Check and add user account to call (app only not working for search queries)

 

#
06/21/2016 18:36:51.14 w3wp.exe (0x2FD0) 0x1EE8 SharePoint Foundation Claims Authentication 8306 Critical An exception occurred when trying to issue security token: 3001002;reason=The incoming identity is not mapped to any user profile account in SharePoint. Possible cause is that no user profiles are created in user profile database. Contact your administrator.. 835c889d-4f44-d015-1370-d70a91212ea1

#

oy wey

SharePoint provider hosted apps errors