LinkedInHelperPublishShareOnLinkedInCompanyProfile Method |
Publishes a new share on company profile identified by
LinkedInAccountID.
The share is visible to anyone.
Namespace: CMS.SocialMarketingAssembly: CMS.SocialMarketing (in CMS.SocialMarketing.dll) Version: 13.0.131
Syntax public static string PublishShareOnLinkedInCompanyProfile(
int accountId,
string comment
)
Parameters
- accountId
- Type: SystemInt32
Identifier of the account info object (company profile). - comment
- Type: SystemString
Comment text.
Return Value
Type:
StringUpdate key of the published share.
Exceptions Exception | Condition |
---|
ArgumentException | Thrown when authorization or LinkedIn's company ID resulting from accountId is null, or when comment is null. |
ArgumentOutOfRangeException | Thrown when comment is longer than COMPANY_SHARE_COMMENT_MAX_LENGTH |
LinkedInApiUnauthorizedException | Thrown when protocol error occurs because the request is not authorized properly. |
LinkedInApiException | Thrown when protocol error occurs. |
ProtocolViolationException | Thrown when request was not issued correctly or when unexpected (other than 201 Created) response for publishing request is returned. |
See Also