Smartsheet.Api.Internal.AttachmentVersioningResourcesImpl.AttachNewVersion C# (CSharp) Method

AttachNewVersion() public method

Uploads a new version of a file to a Sheet or Row. This operation can be performed using a simple upload or a multipart upload. For more information, see Posting an Attachment.

It mirrors To the following Smartsheet REST API method:
POST /sheets/{sheetId}/attachments/{attachmentId}/versions

Uploading new versions is not supported for attachments on Comments or for URL attachments.

This is a resource-intensive operation and incurs 10 additional requests against the rate limit.

if any argument is null or empty string if there is any problem with the REST API request if there is any problem with the REST API authorization (access token) if the resource cannot be found if the REST API service is not available (possibly due To rate limiting) if there is any other error during the operation
public AttachNewVersion ( long sheetId, long attachmentId, string file, string fileType ) : Attachment
sheetId long the sheet id
attachmentId long the attachment id
file string the file path
fileType string the file type
return Smartsheet.Api.Models.Attachment
        public virtual Attachment AttachNewVersion(long sheetId, long attachmentId, string file, string fileType)
        {
            return AttachFile("sheets/" + sheetId + "/attachments/" + attachmentId + "/versions", file, fileType);
        }