Dear Sir/Madam
I am trying out a trial version of your RadControls for Silverlight4 product (2011_2_0712 & 2011_2_0920) on IIS 6 ASP.NET 3.5, using VS2010 and Blend4.
If I hit the cancel button while a file is being uploaded, the upload stops and the partial file is deleted from the disk. If I hit the cancel button after a file has been uploaded, the file is removed from the interface but it is not deleted from the disk.
Is there a way I can make the cancel button delete the file even after the upload is finished?
To be more specific, I have a CancelButton which is initially hidden:
<StackPanel HorizontalAlignment="Right" Margin="3" Orientation="Horizontal" VerticalAlignment="Center">
<telerik:RadButton x:Name="CancelButton" Content="Cancel" Command="{TemplateBinding CancelCommand}" Margin="5" Padding="15 3" telerik:LocalizationManager.ResourceKey="UploadCancel" telerik:StyleManager.Theme="{StaticResource Theme}" Visibility="Collapsed"/>
When the file is uploaded, it is visible:
<VisualState x:Name="Uploaded">
<Storyboard>
<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="CancelButton">
<DiscreteObjectKeyFrame KeyTime="00:00:00" Value="Visible"/>
Using your example file in [1], I saw that the Cancel event is not called when the visible cancel button is pressed after the upload has finished.
I have already read in [2] that you suggest to: "...modify the default style of the RadUpload and either bind the Command of the Cancel button to a custom one or handle its Click event so that you know when this button has been cancelled. Then you can add your custom code and call Upload.CancelUpload() method."
I have also read in [3] though, that this is supposed to be a resolved issue and that it should not be happening. So, is this behavior expected/programmed or is it a bug?
Waiting for your response. Thank you.
[1] http://www.telerik.com/ClientsFiles/150070_203565-example-20090924-1522.zip
[2] http://www.telerik.com/community/forums/silverlight/upload/how-to-handle-the-upload-cancel-event.aspx
[3] http://www.telerik.com/support/pits.aspx#/public/silverlight/2434