PerConnectionBandwidthLimit Property

Object: SoftArtisans.FileUp
Syntax: PerConnectionBandwidthLimit[= Kilobytes As Long]
Type: Long
Read/Write: Read/Write
Description:

This property, when used in conjunction with the TransferFile method for downloads, will limit each connection to a specific bandwidth.

If PerConnectionBandwidthLimit is set, each individual download will not exceed the designated speed. By default, PerConnectionBandwidthLimit is set to 0, meaning no effect. This property is set in kilobytes.

Note: PerConnectionBandwidthLimit is implemented on NT4 with IIS4 or higher, and Windows 2000.
Examples:
ASP <%
'--- Create an instance of SoftArtisans FileUp
Set fileDownload = Server.CreateObject(SoftArtisans.FileUp)

'--- Set bandwidth limit to 10 KB per connection
fileDownload.PerConnectionBandwidthLimit = 10

'--- Start the download
fileDownload.TransferFile "C:\MyServerDir\filename.doc"
%>
C# //--- Create an instance of SoftArtisans FileUp
FileUp fileDownload = new FileUp(Context);

//--- Set bandwidth limit to 10 KB per connection
fileDownload.PerConnectionBandwidthLimit = 10;

//--- Start the download
fileDownload.TransferFile("C:\MyServerDir\filename.doc");
VB.NET '--- Create an instance of SoftArtisans FileUp
Dim fileDownload As New FileUp(Context)

'--- Set bandwidth limit to 10 KB per connection
fileDownload.PerConnectionBandwidthLimit = 10

'--- Start the download
fileDownload.TransferFile("C:\MyServerDir\filename.doc")

Copyright © 2010 SoftArtisans, Inc. All rights reserved.