i have an async upload task.Into that upload function :
AddHandler fileTransferUtilityRequest.UploadProgressEvent,
Sub(sender As Object, e As UploadProgressArgs)
ProgressForm.CPBar1.Value = 0
Dim percent As Integer = convert.toint32(e.transferredbytes) 'e.transferredbytes as long
myProgress = New Progress(Of Integer)(AddressOf ReportProgress)
myProgress.Report(percent)
End Sub
actually the progressbar1.maximum=convert.toint32(sizeofupload)
and the progressbar1.minimum=0
ofcourse, sizeofupload
variable's type is as long
then about theReportProgress
is,
Public Sub ReportProgress(ByVal myInt As Integer)
ProgressForm.CPBar1.Value = myInt
End Sub
i have converted all long type values in int32 type.
but,it does n't worked. the error shows value should be between maximum and minimum.!
i want to progress the transferred bytes in my progress bar while uploading.e.transferredbytes as long
variable
had the transferredbytes value. so,can anyone knows what i'm missed?