Click or drag to resize
IBizFormFileServiceSaveUploadedFileAsTempFile Method
Saves uploaded form file as a temporary file to the file system. The file can be optionally resized if it is an image file. The type of the file is determined from the postedFile's FileName.

Namespace: CMS.OnlineForms
Assembly: CMS.OnlineForms (in CMS.OnlineForms.dll) Version: 12.0.0
Syntax
C#
void SaveUploadedFileAsTempFile(
	HttpPostedFileBase postedFile,
	string tempFileIdentifier,
	string tempFilesFolderPath,
	int width,
	int height,
	int maxSideSize
)

Parameters

postedFile
Type: System.WebHttpPostedFileBase
Posted file from a client.
tempFileIdentifier
Type: SystemString
Identifier of the temporary file to derive file name from.
tempFilesFolderPath
Type: SystemString
Folder path where temporary form files are being saved.
width
Type: SystemInt32
Required image width to resize the postedFile to if the file is an image file, or 0.
height
Type: SystemInt32
Required image height to resize the postedFile to if the file is an image file, or 0.
maxSideSize
Type: SystemInt32
Required image max side size to resize the postedFile to if the file is an image file, or 0.
Exceptions
ExceptionCondition
ArgumentNullExceptionThrown when postedFile is null.
ArgumentExceptionThrown when tempFileIdentifier or tempFilesFolderPath is null or an empty string.
See Also