|
|
EsCRC - ActiveX controlEurosource, Gruvbyn 415, S-820 50 LOOS, Sweden With this control you can calculate a 32-bit CRC on Files, Buffers and Strings. It is perfect for situation where you need to make shore that the original data is kept intact during a transfer of some form.
InstallationTransfer EsCrc32.OCX to your \windows\system or \winnt35\system32 directory and register it by executing the command: RegSvr32 \Windows\System\EsCRC32.OCXRegSvr32.exe can be found on the Visual Basic 4.0 CD-ROM and in our dll archive (www.eurosource.se). If RegSvr32.exe fails, it's probably because you don't have the MFC 4.0 DLL library installed on your system. This is available from many sources on the Internet including our ftp archive as MFC40DLL.ZIP. Regsvr32.exe is also included in this archive. If you want to check if you already got the files in mfc40dll.zip they are
Cookbook or how to use the EsCRC ControlCreate a EsCRC object for an ASP applicationUse the object ID ESCRC.EsCRCCtrl.1 when you create an instance of the
EsCRCCtrl. Calculate the CRC for a buffer
Calculate the CRC for a file
Calculate the CRC for a string
Properties
short Buf( long index)You can use the buf property to set or fetch data from a buffer. Before using this property you should set the Length property to the desired length of the buffer. LPSTR InFileThis property holds the name of a file for which a CRC should be calculated.
long LengthThis is the size of the controls internal buffer. You can manipulate the content of this buffer with the Buf property.
long Crc32This property holds the result after a completed CRC calculation.
MethodsBOOL CalcCrcOnBufWith this method you can calculate the CRC for the content in a buffer defined by the Buf property and the Length property respectively. The method returns TRUE if the calculation completes and the result can then be found in the CRC32 property. BOOL CalcCrcOnFileWith this method you can calculate the CRC for a file which path is defined by the InFile property. The method returns TRUE if the calculation completes and the result can then be found in the CRC32 property.
BOOL CalcCrcOnString (LPCSTR string)With this method you can calculate the CRC for a string supplied as its argument. The method returns TRUE if the calculation completes and the result can then be found in the CRC32 property. Eventsstatus (short progress)Certain operations take some time to complete. This event gives you information about how much of the job that has been completed. When a lengthy job starts the status event is fired with progress set to 0 and then you get status events until the job is complete and a status event with progress set to 100 is fired. You therefore only need to write the progress to a gauge control to give your users dynamic information. Where to get the control?It is possible that you are reading this documentation without having access to the control itself. If you have Internet access you just need to connect to http://www.eurosource.se and fetch a fully working sample of the control. At this location you can also find samples on how to use the control. We can email the control anywhere in the world if you send us a request to do so. Please state if you want MIME or BINHEX coding. Send request to sales@eurosource.se If you use the unregistered version of the control a splash screen is displayed from time to time reminding you to register.To get rid of this nag-screen you need to register. Information is available at our site. We ship anywhere in the world with World-wide First Class/Airmail if you select this option. The only media supported is 3.5" diskettes.The charge for this type of delivery is $15 (USD) extra. SupportYou can get support by sending email to support@eurosource.se. You can also find relevant information on-line at http://www.eurosource.se We also check the newsgroup comp.lang.basic.visual.3rdparty on a regular basis and will try to help on all questions posted there. How to contact us
|