Back to product page

LocalCRC method


Calculates integrity check of local file.

Type

String

Syntax

  • C#
  • VB.NET
public String LocalCRC(IntegrityCheckTypes Type);
The LocalCRC(Type) syntax has these parts:
TypeDetermines type of integrity check algorithm used.

public String LocalCRC(IntegrityCheckTypes Type, String LocalPath);
The LocalCRC(Type,LocalPath) syntax has these parts:
TypeDetermines type of integrity check algorithm used.
LocalPathFull path to a file on local system.

public String LocalCRC(IntegrityCheckTypes Type, String LocalPath, Int32 FileStart, Int32 FileLength);
The LocalCRC(Type,LocalPath,FileStart,FileLength) syntax has these parts:
TypeDetermines type of integrity check algorithm used.
LocalPathFull path to a file on local system.
FileStartInteger value that represents starting position in the file for calculating CRC.
FileLengthInteger value that represents length of data in the file where CRC is calculated.

public Function LocalCRC(ByVal Type As IntegrityCheckTypes) As String
The LocalCRC(Type) syntax has these parts:
TypeDetermines type of integrity check algorithm used.

public Function LocalCRC(ByVal Type As IntegrityCheckTypes, ByVal LocalPath As String) As String
The LocalCRC(Type,LocalPath) syntax has these parts:
TypeDetermines type of integrity check algorithm used.
LocalPathFull path to a file on local system.

public Function LocalCRC(ByVal Type As IntegrityCheckTypes, ByVal LocalPath As String, ByVal FileStart As Int32, ByVal FileLength As Int32) As String
The LocalCRC(Type,LocalPath,FileStart,FileLength) syntax has these parts:
TypeDetermines type of integrity check algorithm used.
LocalPathFull path to a file on local system.
FileStartInteger value that represents starting position in the file for calculating CRC.
FileLengthInteger value that represents length of data in the file where CRC is calculated.

Remarks

LocalCRC method will calculate checksum of local file using any of supported algorithms (CRC, MD5...). For CRC it will be a long value represented in HEX characters (such as ABCDEF01), for MD5 hash it will be 16 HEX numbers (meaning 32 ASCII chars as its readable representation), and for SHA1 it will be 20 HEX numbers. Please note that not many servers support these functions. CRC is most widely supported, so you should use that method if you're unsure how good remote FTP server is.

Platforms

Windows