Top Banner
ComponentOne Uploader for Silverlight
195

ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

Jan 27, 2020

Download

Documents

dariahiddleston
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

ComponentOne

Uploader for Silverlight

Page 2: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

Copyright © 1987-2015 GrapeCity, Inc. All rights reserved.

ComponentOne, a division of GrapeCity

201 South Highland Avenue, Third Floor

Pittsburgh, PA 15206 USA

Website: http://www.componentone.com

Sales: [email protected]

Telephone: 1.800.858.2739 or 1.412.681.4343 (Pittsburgh, PA USA Office)

Trademarks

The ComponentOne product name is a trademark and ComponentOne is a registered trademark of GrapeCity, Inc.

All other trademarks used herein are the properties of their respective owners.

Warranty

ComponentOne warrants that the media on which the software is delivered is free from defects in material and

workmanship, assuming normal use, for a period of 90 days from the date of purchase. If a defect occurs during this

time, you may return the defective media to ComponentOne, along with a dated proof of purchase, and

ComponentOne will replace it at no charge. After 90 days, you can obtain a replacement for the defective media by

sending it and a check for $25 (to cover postage and handling) to ComponentOne.

Except for the express warranty of the original media on which the software is delivered is set forth here,

ComponentOne makes no other warranties, express or implied. Every attempt has been made to ensure that the

information contained in this manual is correct as of the time it was written. ComponentOne is not responsible for

any errors or omissions. ComponentOne’s liability is limited to the amount you paid for the product. ComponentOne

is not liable for any special, consequential, or other damages for any reason.

Copying and Distribution

While you are welcome to make backup copies of the software for your own use and protection, you are not

permitted to make copies for the use of anyone else. We put a lot of time and effort into creating this product, and

we appreciate your support in seeing that it is used by licensed users only.

Page 3: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

1

Table of Contents Uploader for Silverlight ................................................................................................................. 8

Help with ComponentOne Studio Silverlight Edition ................................................................ 8

Uploader for Silverlight Key Features ........................................................................................... 8

Uploader for Silverlight Quick Start .............................................................................................. 9

Step 1 of 4: Creating a Silverlight Application........................................................................... 9

Step 2 of 4: Adding Code to the Project ................................................................................. 10

Step 3 of 4: Implementing Server Code .................................................................................. 17

Step 4 of 4: Running the Application ...................................................................................... 20

Working with Uploader for Silverlight ........................................................................................ 21

Basic Properties ...................................................................................................................... 21

Basic Methods ......................................................................................................................... 22

Basic Events ............................................................................................................................ 22

Uploading Files ........................................................................................................................ 23

Silverlight and Local Files ........................................................................................................ 23

Maximum Upload Size ............................................................................................................ 24

Parameters .............................................................................................................................. 24

Uploader for Silverlight Samples ................................................................................................ 25

Uploader for Silverlight Task-Based Help ................................................................................... 25

Splitting Files ........................................................................................................................... 26

Cancelling a File Upload .......................................................................................................... 27

Determining whether C1Uploader is Busy.............................................................................. 27

Compressing and Uploading Files ........................................................................................... 28

Uploading and Previewing Files .............................................................................................. 37

API ............................................................................................................................................... 44

C1.Silverlight.Uploader.5 Assembly ........................................................................................ 44

Namespaces ........................................................................................................................ 44

C1.Silverlight.Uploader Namespace ............................................................................... 44

Overview ..................................................................................................................... 44

Classes ......................................................................................................................... 46

C1Uploader ............................................................................................................. 46

Overview ............................................................................................................. 47

Members ............................................................................................................. 48

Methods .............................................................................................................. 49

Page 4: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

2

AddFile Method .............................................................................................. 50

AddFile(FileInfo) Method ............................................................................ 50

AddFile(String) Method ............................................................................... 51

AddFile(String,Stream) Method .................................................................. 52

AddFiles Method ............................................................................................. 53

BeginUploadFiles Method ............................................................................... 54

Cancel Method ................................................................................................ 55

Properties ............................................................................................................ 55

Files Property .................................................................................................. 56

Headers Property ............................................................................................ 56

IsBusy Property ............................................................................................... 57

MaximumUploadSize Property ....................................................................... 57

Parameters Property ....................................................................................... 58

Settings Property ............................................................................................ 58

UserState Property ......................................................................................... 59

Events .................................................................................................................. 59

UploadCompleted Event ................................................................................. 60

UploadProgressChanged Event ....................................................................... 61

C1UploaderPost ...................................................................................................... 62

Overview ............................................................................................................. 63

Members ............................................................................................................. 63

C1UploaderPost Constructor .............................................................................. 65

C1UploaderPost Constructor(Uri) ................................................................... 66

C1UploaderPost Constructor(FilesPerRequest) .............................................. 67

C1UploaderPost Constructor(UploadManagerSettingsPost) ......................... 68

C1UploaderPost Constructor(UploadManagerSettingsPost,FilePackager) .... 68

Properties ............................................................................................................ 69

Settings Property ............................................................................................ 70

Events .................................................................................................................. 70

MIMETypeRequested Event ........................................................................... 71

C1UploaderWebService .......................................................................................... 72

Overview ............................................................................................................. 72

Members ............................................................................................................. 73

C1UploaderWebService Constructor .................................................................. 75

C1UploaderWebService Constructor(Uri) ....................................................... 76

C1UploaderWebService Constructor(FilesPerRequest) .................................. 77

Page 5: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

3

C1UploaderWebService Constructor(UploadManagerSettingsWebService) . 77

C1UploaderWebService

Constructor(UploadManagerSettingsWebService,FilePackager) ................... 78

Properties ............................................................................................................ 79

Settings Property ............................................................................................ 80

FilePackager ............................................................................................................ 80

Overview ............................................................................................................. 81

Members ............................................................................................................. 82

Methods .............................................................................................................. 83

GetMaxSizePerUpload Method ...................................................................... 83

GetPackages Method ...................................................................................... 84

GetTotalSize Method ...................................................................................... 84

Properties ............................................................................................................ 85

Files Property .................................................................................................. 85

MaximumUploadSize Property ....................................................................... 86

FilePackagerFactory ................................................................................................ 86

Overview ............................................................................................................. 87

Members ............................................................................................................. 88

Methods .............................................................................................................. 88

Create Method ................................................................................................ 88

FilePackagerMultiFile .............................................................................................. 89

Overview ............................................................................................................. 90

Members ............................................................................................................. 91

FilePackagerMultiFile Constructor ...................................................................... 92

Methods .............................................................................................................. 92

GetMaxSizePerUpload Method ...................................................................... 93

GetPackages Method ...................................................................................... 93

FilePackagerPartialFile ............................................................................................ 94

Overview ............................................................................................................. 95

Members ............................................................................................................. 95

FilePackagerPartialFile Constructor .................................................................... 96

Methods .............................................................................................................. 97

GetMaxSizePerUpload Method ...................................................................... 97

GetPackages Method ...................................................................................... 98

FilePackagerSingleFile ............................................................................................. 99

Overview ............................................................................................................. 99

Page 6: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

4

Members ........................................................................................................... 100

FilePackagerSingleFile Constructor ................................................................... 101

Methods ............................................................................................................ 101

GetMaxSizePerUpload Method .................................................................... 102

GetPackages Method .................................................................................... 103

InvalidAddressException ....................................................................................... 103

Overview ........................................................................................................... 104

Members ........................................................................................................... 105

InvalidAddressException Constructor ............................................................... 106

InvalidAddressException Constructor() ........................................................ 106

InvalidAddressException Constructor(Exception) ........................................ 107

MaximumUploadSizeExceededException ............................................................. 108

Overview ........................................................................................................... 108

Members ........................................................................................................... 109

MaximumUploadSizeExceededException Constructor..................................... 110

MIMETypeRequestedEventArgs ........................................................................... 111

Overview ........................................................................................................... 112

Members ........................................................................................................... 112

Properties .......................................................................................................... 113

FileExtension Property .................................................................................. 113

UploadCompletedEventArgs ................................................................................. 114

Overview ........................................................................................................... 114

Members ........................................................................................................... 115

UploadCompletedEventArgs Constructor ......................................................... 116

Properties .......................................................................................................... 118

Files Property ................................................................................................ 118

Response Property ........................................................................................ 119

Success Property ........................................................................................... 119

UploadFileInfo ....................................................................................................... 120

Overview ........................................................................................................... 120

Members ........................................................................................................... 121

UploadFileInfo Constructor ............................................................................... 122

UploadFileInfo Constructor(FileInfo) ............................................................ 122

UploadFileInfo Constructor(String) ............................................................... 123

UploadFileInfo Constructor(String,Stream) .................................................. 124

Methods ............................................................................................................ 125

Page 7: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

5

Close Method ................................................................................................ 125

GetSize Method ............................................................................................ 126

Prepare Method ............................................................................................ 126

Properties .......................................................................................................... 127

File Property .................................................................................................. 127

Name Property .............................................................................................. 128

UploadFilePartInfo ................................................................................................ 128

Overview ........................................................................................................... 129

Members ........................................................................................................... 130

UploadFilePartInfo Constructor ........................................................................ 131

UploadFilePartInfo Constructor(String,Byte[],Int32,Int32) .......................... 131

UploadFilePartInfo Constructor(UploadFileInfo) .......................................... 132

Methods ............................................................................................................ 133

GetSize Method ............................................................................................ 133

Properties .......................................................................................................... 134

Data Property ................................................................................................ 134

Name Property .............................................................................................. 135

PartCount Property ....................................................................................... 135

PartNumber Property ................................................................................... 136

UploadFilePartPackage ......................................................................................... 136

Overview ........................................................................................................... 137

Members ........................................................................................................... 138

UploadFilePartPackage Constructor ................................................................. 141

Methods ............................................................................................................ 142

GetSize Method ............................................................................................ 145

Properties .......................................................................................................... 145

ServerWaitForOneFile Property .................................................................... 146

UploadManagerPost ............................................................................................. 146

Overview ........................................................................................................... 147

Members ........................................................................................................... 147

UploadManagerPost Constructor ..................................................................... 148

Methods ............................................................................................................ 149

BeginUpload Method .................................................................................... 149

Cancel Method .............................................................................................. 150

Events ................................................................................................................ 151

UploadCompleted Event ............................................................................... 151

Page 8: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

6

UploadProgressChanged Event ..................................................................... 152

UploadManagerSettings ....................................................................................... 153

Overview ........................................................................................................... 154

Members ........................................................................................................... 155

Properties .......................................................................................................... 155

Address Property .......................................................................................... 155

UploadManagerSettingsPost ................................................................................ 156

Overview ........................................................................................................... 157

Members ........................................................................................................... 157

UploadManagerSettingsPost Constructor ........................................................ 158

UploadManagerSettingsPost Constructor(Uri) ............................................. 159

UploadManagerSettingsPost Constructor() .................................................. 159

Properties .......................................................................................................... 160

Boundary Property ........................................................................................ 160

TransferEncoding Property ........................................................................... 161

UploadManagerSettingsWebService .................................................................... 161

Overview ........................................................................................................... 162

Members ........................................................................................................... 163

UploadManagerSettingsWebService Constructor ............................................ 164

UploadManagerSettingsWebService Constructor(Uri) ................................. 165

UploadManagerSettingsWebService Constructor() ...................................... 165

Properties .......................................................................................................... 166

MethodManyFiles Property .......................................................................... 167

MethodOneFile Property .............................................................................. 167

Namespace Property .................................................................................... 168

ParamFileData Property ................................................................................ 168

ParamFileName Property .............................................................................. 169

ParamFiles Property ...................................................................................... 169

ParamParameters Property .......................................................................... 170

ParamPartCount Property ............................................................................ 171

ParamPartNumber Property ......................................................................... 171

UploadManagerWebService ................................................................................. 172

Overview ........................................................................................................... 173

Members ........................................................................................................... 173

UploadManagerWebService Constructor ......................................................... 174

Methods ............................................................................................................ 175

Page 9: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

7

BeginUpload Method .................................................................................... 175

Cancel Method .............................................................................................. 176

Events ................................................................................................................ 177

UploadCompleted Event ............................................................................... 177

UploadProgressChanged Event ..................................................................... 178

UploadProgressChangedEventArgs ...................................................................... 179

Overview ........................................................................................................... 180

Members ........................................................................................................... 180

UploadProgressChangedEventArgs Constructor .............................................. 181

Properties .......................................................................................................... 182

BytesUploaded Property ............................................................................... 183

ProgressPercentage Property ....................................................................... 183

TotalBytesToUpload Property ....................................................................... 184

UserState Property ....................................................................................... 184

Enumerations ............................................................................................................ 185

FilesPerRequest ..................................................................................................... 185

MultipartPostEncoding ......................................................................................... 186

Interfaces .................................................................................................................. 186

IUploadManager ................................................................................................... 186

Overview ........................................................................................................... 187

Members ........................................................................................................... 188

Methods ............................................................................................................ 188

BeginUpload Method .................................................................................... 189

Cancel Method .............................................................................................. 190

Events ................................................................................................................ 190

UploadCompleted Event ............................................................................... 191

UploadProgressChanged Event ..................................................................... 192

Delegates .................................................................................................................. 193

C1UploaderPost.MIMETypeRequestedEventHandler .......................................... 193

Page 10: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

8

Uploader for Silverlight Upload files to the server from your Silverlight applications with Uploader for Silverlight.

Uploader for Silverlight provides a simple and reliable way to upload files and streams to the

server.

See Also

Help with ComponentOne Studio Silverlight Edition

Help with ComponentOne Studio

Silverlight Edition Uploader for Silverlight > Help with ComponentOne Studio Silverlight Edition

Getting Started

For information on installing ComponentOne Studio Silverlight Edition, licensing, technical

support, namespaces and creating a project with the control, please visit Getting Started with

Silverlight Edition.

See Also

Uploader for Silverlight Key Features

Uploader for Silverlight Key Features Uploader for Silverlight includes several key features, such as:

File Size Limitation

Set the maximum file size for file upload requests. See Maximum Upload Size for more

information.

Asynchronous File Upload

The end-user can select multiple files at a time using the FilePicker for Silverlight

control, and the C1Uploader control loads the files asynchronously.

Use Multipart Post Messages

The C1UploaderPost object enables you to upload files to the server using multipart

post messages.

Use Web Services

Use the C1UploaderWebService object to upload files to the server using Web services.

Upload Large Files

You can upload large files without changing any server configurations. Uploader for

Silverlight can split the stream into small pieces, and rejoin them on the server.

Upload Files from Multiple Sources

Upload content from a selected file in the end-user machine, an isolated storage file, or

any stream in memory.

Page 11: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

9

See Also Uploader for Silverlight Quick Start

Uploader for Silverlight Quick Start The following quick start guide is intended to get you up and running with Uploader for

Silverlight. In this quick start we create a new project in Visual Studio, add the C1Uploader

class to the application, and set up the application to upload files.

See Also

Step 1 of 4: Creating a Silverlight Application

Step 2 of 4: Adding Code to the Project

Step 3 of 4: Implementing Server Code

Step 4 of 4: Running the Application

Step 1 of 4: Creating a Silverlight

Application Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight Application

In this step we begin in Visual Studio to create a Silverlight application using Uploader for

Silverlight. We create a new Silverlight project and set up the application.

To set up your project, complete the following steps:

1. In Visual Studio, select File | New | Project.

2. In the New Project dialog box, select a language in the left pane, and in the templates

list select Silverlight Application. Enter a Name for your project, for example

"QuickStart," and click OK. The New Silverlight Application dialog box appears.

3. Click OK to accept the default settings, close the New Silverlight Application dialog

box, and create your project. The MainPage.xaml file opens.

4. Right-click the project in the Solution Explorer window and select Add Reference.

5. In the Add Reference dialog box, locate and select the C1.Silverlight.dll and

C1.Silverlight.Uploader.dll assemblies and click OK to add references to your project.

6. In the XAML window of the project, place the cursor between the <Grid> and </Grid>

tags and click once.

7. Add the following XAML markup between the <Grid> and </Grid> tags in the

MainPage.xaml file:

XAML Copy Code

Page 12: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

10

<StackPanel Orientation="Horizontal" Height="250"

HorizontalAlignment="Center">

<Button Content="Upload Photos" Height="30" VerticalAlignment="Top"

Margin="5" Click="Upload_Click" />

<ScrollViewer Width="400" Margin="5" Background="White">

<StackPanel x:Name="PicturePanel"/>

</ScrollViewer>

</StackPanel>

8. This markup creates a button and a panel. Users click the button to upload image files

to the server and the panel displays the images.

9. Right-click the QuickStartWeb application in the Solution Explorer and select New

Folder. Name the folder "Pictures." Note that if you name your project something other

than "QuickStart" you right-click MyProjectWeb where "MyProject" is the name of your

project.

This folder is used to save the uploaded images. After you create the Pictures folder,

you may need to set up its permissions so the application can save the pictures into the

folder. You may need to confirm that the network service has read and write

permissions on the folder.

What You've Accomplished

You have successfully created and set up a Silverlight application and added controls to the

page. In the next step we add code to implement the C1Uploader class.

See Also

Step 2 of 4: Adding Code to the Project

Step 2 of 4: Adding Code to the Project Uploader for Silverlight Quick Start > Step 2 of 4: Adding Code to the Project

In the last step you set up a Silverlight application, but if you run your application now, the

button and panel do nothing. In this step we continue in Visual Studio by adding code to your

project to implement the C1Uploader class.

To implement the C1Uploader class, complete the following steps:

1. Navigate to the Solution Explorer, right-click the MainPage.xaml file, and select View

Code to switch to Code view.

2. In Code view, add the following import statements to the top of the page if they are

not included:

Visual Basic Copy Code

Page 13: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

11

Imports System.Windows.Controls

Imports System.IO

Imports System.Diagnostics

Imports C1.Silverlight

Imports C1.Silverlight.Uploader

3.

C# Copy Code

using System.Windows.Controls;

using System.IO;

using System.Diagnostics;

using C1.Silverlight;

using C1.Silverlight.Uploader;

4. Add the following event handler to the MainPage.xaml.cs file, below all of the other

methods in the MainPage class:

Visual Basic Copy Code

Private Sub Upload_Click(ByVal sender As Object, ByVal e As

RoutedEventArgs)

' Configure OpenFileDialog

Dim dlg As New OpenFileDialog()

dlg.Filter = "All|*.*|Images|*.jpg;*.png;*.gif"

dlg.FilterIndex = 2

dlg.Multiselect = True

' Show OpenFileDialog

If CBool(dlg.ShowDialog()) Then

Try

' Check that the files really are images

For Each fdi As FileInfo In dlg.Files

Dim img As New System.Windows.Media.Imaging.BitmapImage()

img.SetSource(fdi.OpenRead())

Next

Catch

Page 14: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

12

C1MessageBox.Show("Sorry, at least one of the selected files is not

an image.",

"Upload Canceled", C1MessageBoxButton.OK,

C1MessageBoxIcon.Warning)

Exit Sub

End Try

' Create and configure uploader

Dim uri As Uri = BuildAbsoluteUri("photoUpload.ashx")

Dim uploader As C1Uploader = New C1UploaderPost(uri)

AddHandler uploader.UploadProgressChanged, AddressOf

uploader_UploadProgressChanged

AddHandler uploader.UploadCompleted, AddressOf

uploader_UploadCompleted

' Upload selected files

uploader.AddFiles(dlg.Files)

uploader.BeginUploadFiles()

End If

End Sub

5.

C# Copy Code

private void Upload_Click(object sender, RoutedEventArgs e)

{

// Configure OpenFileDialog

OpenFileDialog dlg = new OpenFileDialog();

dlg.Filter = "All|*.*|Images|*.jpg;*.png;*.gif";

dlg.FilterIndex = 2;

dlg.Multiselect = true;

// Show OpenFileDialog

if ((bool)dlg.ShowDialog())

{

try

{

// Check that the files really are images

foreach (FileInfo fdi in dlg.Files)

Page 15: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

13

{

System.Windows.Media.Imaging.BitmapImage img = new

System.Windows.Media.Imaging.BitmapImage();

img.SetSource(fdi.OpenRead());

}

}

catch

{

C1MessageBox.Show(

"Sorry, at least one of the selected files doesn't appear to be

an image.",

"Upload Canceled", C1MessageBoxButton.OK,

C1MessageBoxIcon.Warning);

return;

}

// Create and configure uploader

Uri uri = BuildAbsoluteUri("photoUpload.ashx");

C1Uploader uploader = new C1UploaderPost(uri);

uploader.UploadProgressChanged += uploader_UploadProgressChanged;

uploader.UploadCompleted += uploader_UploadCompleted;

// Upload selected files

uploader.AddFiles(dlg.Files);

uploader.BeginUploadFiles();

}

}

6. This event handler initially displays an OpenFileDialog for the user to select files to

upload. Silverlight runs in a secure sandbox environment, and you cannot get direct

access to the file system. But the OpenFileDialog class grants access to specific files

explicitly selected by the user. You can also get access to files in the IsolatedStorage

area.

Once the files areselected, the code checks whether the files really are images. It does

this by creating BitmapImage objects and loading the files into the objects. If the file

does not contain an image, then an exception occurs and the process is aborted. This

check prevents users from uploading files of the wrong type, either by mistake or with

malicious intent. Later, we also perform a similar security check on the server.

After the files are validated, the code creates a new C1UploaderPost object. There are

two types of C1Uploader object, the C1UploaderPost and C1UploaderWebService.

The difference between the two is how files are received on the server.

C1UploaderPost uses a multipart POST protocol that is very convenient, as you can see

in the next steps.

7. Add the following event handler to your project:

Page 16: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

14

Visual Basic Copy Code

Public Shared Function BuildAbsoluteUri(ByVal relativeUri As String) As Uri

' Get current absolute Uri; this depends on where the app is deployed

Dim uri As Uri = System.Windows.Browser.HtmlPage.Document.DocumentUri

Dim uriString As String = uri.AbsoluteUri

' Replace page name with relative service Uri

Dim ls As Integer = uriString.LastIndexOf("/"c)

uriString = uriString.Substring(0, ls + 1) + relativeUri

' Return new Uri

Return New Uri(uriString, UriKind.Absolute)

End Function

8.

C# Copy Code

public static Uri BuildAbsoluteUri(string relativeUri)

{

// Get current absolute Uri; this depends on where the app is deployed

Uri uri = System.Windows.Browser.HtmlPage.Document.DocumentUri;

string uriString = uri.AbsoluteUri;

// Replace page name with relative service Uri

int ls = uriString.LastIndexOf('/');

uriString = uriString.Substring(0, ls + 1) + relativeUri;

// Return new Uri

return new Uri(uriString, UriKind.Absolute);

}

9. The C1UploaderPost constructor requires a parameter that specifies the Uri of the

handler that processes the files on the server. Silverlight requires an absolute Uri, so the

code uses a helper method called BuildAbsoluteUri that works whether the application

is running on a development machine or on a production server.

The code also attaches event handlers to the UploadProgressChanged

and UploadCompleted events of the new C1Uploader. The code you add in the next

Page 17: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

15

step uses the first to check the progress of the upload process, and the second to

display the files that are uploaded.

10. Add the following event handlers to your project:

Visual Basic Copy Code

Private Sub uploader_UploadProgressChanged(ByVal sender As Object, ByVal e

As C1.Silverlight.Uploader.UploadProgressChangedEventArgs)

Debug.WriteLine("uploaded {0} of {1} bytes, {2}%", e.BytesUploaded,

e.TotalBytesToUpload, e.ProgressPercentage)

End Sub

Private Sub uploader_UploadCompleted(ByVal sender As Object, ByVal e As

UploadCompletedEventArgs)

If e.Success Then

For Each fileName As String In e.Files

' Holder for picture and title

Dim picHolder As New StackPanel()

picHolder.Width = 200

' Create Image to show the picture

Dim bmp As New System.Windows.Media.Imaging.BitmapImage()

bmp.UriSource = BuildAbsoluteUri("Pictures/" & fileName)

Dim img As New Image()

img.Source = bmp

img.Margin = New Thickness(10, 10, 10, 0)

picHolder.Children.Add(img)

' Create image title

Dim tb As New TextBlock()

tb.Text = fileName

tb.FontSize = 12

tb.HorizontalAlignment = HorizontalAlignment.Center

tb.Margin = New Thickness(10, 0, 10, 10)

picHolder.Children.Add(tb)

' Add picture holder to panel

PicturePanel.Children.Add(picHolder)

Next

Else

Debug.WriteLine("Upload failed: {0}", If(e.[Error] IsNot Nothing,

e.[Error].Message, "??"))

End If

Page 18: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

16

End Sub

11.

C# Copy Code

void uploader_UploadProgressChanged(object sender,

C1.Silverlight.Uploader.UploadProgressChangedEventArgs e)

{

Debug.WriteLine("uploaded {0} of {1} bytes, {2}%",

e.BytesUploaded,

e.TotalBytesToUpload,

e.ProgressPercentage);

}

void uploader_UploadCompleted(object sender, UploadCompletedEventArgs e)

{

if (e.Success)

{

foreach (string fileName in e.Files)

{

// Holder for picture and title

StackPanel picHolder = new StackPanel();

picHolder.Background = new SolidColorBrush(Colors.LightGray);

picHolder.Margin = new Thickness(10);

picHolder.Width = 200;

// Create Image to show the picture

System.Windows.Media.Imaging.BitmapImage bmp = new

System.Windows.Media.Imaging.BitmapImage();

bmp.UriSource = BuildAbsoluteUri("Pictures/" + fileName);

Image img = new Image();

img.Source = bmp;

img.Margin = new Thickness(10, 10, 10, 0);

picHolder.Children.Add(img);

// Create image title

TextBlock tb = new TextBlock();

tb.Text = fileName;

tb.FontSize = 12;

tb.HorizontalAlignment = HorizontalAlignment.Center;

Page 19: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

17

tb.Margin = new Thickness(10, 0, 10, 10);

picHolder.Children.Add(tb);

// Add picture holder to panel

PicturePanel.Children.Add(picHolder);

}

}

else

{

Debug.WriteLine("Upload failed: {0}", e.Error != null ?

e.Error.Message : "??");

}

}

12. This code checks whether the upload is successful, and then loops through the files to

create a new Image element for each one. The Image elements are configured to show

the images, assuming they are stored under a "Pictures" folder on the server.

What You've Accomplished

You've successfully created a Silverlight application and added controls to the page. If you run

the project now and try to upload some pictures, you get an error. That is because the

C1Uploader is sending files to the server, but you have not implemented the server code yet. In

the next step we implement the server code.

See Also

Step 3 of 4: Implementing Server Code

Step 3 of 4: Implementing Server Code Uploader for Silverlight Quick Start > Step 3 of 4: Implementing Server Code

In the last steps, you set up a Silverlight application and added code to your application to

implement the client action and behavior, but if you run your application now, you get an error

because the server code is not implemented. In this step we add code to your project to

implement the server code.

To implement the server code, complete the following steps:

1. In the Visual Studio Solution Explorer, right-click the QuickStartWeb solution and

select the Add | New Item option. If you named your project something other than

"QuickStart," right-click MyProjectWeb where "MyProject" is the name of your project.

2. In the Add New Item dialog box, select the Generic Handler template and name the

new class "photoUpload.ashx" (this is the Uri from the C1Uploader object in Step 2 of

4).

3. Click Add to add the file to your project and close the Add New Item dialog box.

Page 20: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

18

4. Open the photoUpload.ashx file and replace the default implementation of the

ProcessRequest method with the following code:

Visual Basic Copy Code

Sub ProcessRequest(ByVal context As HttpContext) Implements

IHttpHandler.ProcessRequest

Const MAXFILES As Integer = 30

' Clean up

Dim path As String = context.Request.MapPath("Pictures")

Dim files As String() = System.IO.Directory.GetFiles(path)

If files.Length >= MAXFILES Then

For Each fileName As String In files

System.IO.File.Delete(fileName)

Next

End If

' Get files being uploaded

Dim i As Integer = 0

While i < context.Request.Files.Count AndAlso i < MAXFILES

Dim file As HttpPostedFile = context.Request.Files(i)

Try

' Check that it really is an image by loading it into an Image

object

Dim img As System.Drawing.Image =

System.Drawing.Image.FromStream(file.InputStream)

' Save file to the Pictures folder

Dim fileName As String = context.Request.MapPath("Pictures/" &

file.FileName)

file.SaveAs(fileName)

Catch

' If it doesn't look like a valid image, skip request

Exit Try

End Try

i += 1

End While

End Sub

Page 21: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

19

5.

C# Copy Code

public void ProcessRequest(HttpContext context)

{

const int MAXFILES = 30;

// Clean up

string path = context.Request.MapPath("Pictures");

string[] files = System.IO.Directory.GetFiles(path);

if (files.Length >= MAXFILES)

{

foreach (string fileName in files)

System.IO.File.Delete(fileName);

}

// Get files being uploaded

for (int i = 0; i < context.Request.Files.Count && i < MAXFILES; i++)

{

HttpPostedFile file = context.Request.Files[i];

try

{

// Check that it really is an image by loading it into an

Image object

System.Drawing.Image img =

System.Drawing.Image.FromStream(file.InputStream);

// Save file to the Pictures folder

string fileName = context.Request.MapPath("Pictures/" +

file.FileName);

file.SaveAs(fileName);

}

catch

{

// If it doesn't look like a valid image, skip request

break;

}

}

}

Page 22: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

20

6. This code starts by cleaning up the images folder in case there are more than 30 images

in it. In a real application you might do this differently, possibly by compressing old

images or enforcing a per-user storage limit.

After the clean-up, the code loops through the files in the context.Request.Files

collection and checks that they really are image files. You already added a similar check

when implementing the server part of the code, but it is important to protect both ends

of the application. Finally, the code saves each image into the Pictures folder.

What You've Accomplished

You've successfully created a Silverlight application that uses the C1Uploader control to upload

files to the server. In the next step we run the application and observe its run time interactions.

See Also

Step 4 of 4: Running the Application

Step 4 of 4: Running the Application Uploader for Silverlight Quick Start > Step 4 of 4: Running the Application

Now that you have created a Silverlight application and added code to implement

the C1Uploader class, the only thing left to do is run your application. To observe your

application's run-time interactions, complete the following steps:

1. Choose Debug | Start Debugging from the menu to run your application. The

application appears with the button and panel visible.

2. Click the Upload Photos button. Observe that the Open dialog box opens and initially

only images are visible in the dialog box.

3. Locate and select a .png or .jpg file and click Open to close the dialog box. Observe

that the image you selected is now visible in the panel. The image is uploaded to the

server, saved in the Pictures folder, then downloaded back to the client by way of the

Image elements that you created in response to the UploadCompleted event.

4. Click the Upload Photos button and click All in the drop-down box next to the File

name box so all files are visible.

5. Choose a non-image file, for example a text file, and click Open. A message appears

indicating that the non-image file cannot be uploaded. This message box was specified

in the code in the previous steps.

6. Click OK to close the message box.

7. Click the Upload Photos button. In the Open dialog box, choose multiple images (click

CTRL as you click each image) and click Open. Observe that you can add multiple

images to the panel at once.

What You've Accomplished

Congratulations! You've successfully completed the Uploader for Silverlight quick start and

created a basic uploading application where image files are uploaded to the server, saved in a

folder, and downloaded back to the client. You created a Silverlight application, added code to

the application, implemented the server code, and ran the application to observe run time

interactions.

Page 23: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

21

See Also

Working with Uploader for Silverlight

Working with Uploader for Silverlight Uploader for Silverlight provides a simple and reliable way to upload files and stream to the

server using the C1Uploader component. You can easily access and implement C1Uploader

using code.

See Also

Basic Properties

Basic Methods

Basic Events

Uploading Files

Silverlight and Local Files

Maximum Upload Size

Parameters

Basic Properties Working with Uploader for Silverlight > Basic Properties

Uploader for Silverlight includes several properties that allow you to set the functionality of

the control. Some of the more important properties are listed below.

The following properties let you customize the C1Uploader control:

Property Description

Files Gets the collection of files that will be uploaded.

Headers Gets the headers that will be sent to the server with each upload.

IsBusy Gets whether the component is currently uploading files.

MaximumUploadSize Gets or sets the maximum size in bytes allowed for each upload.

See Maximum Upload Size for more information.

Parameters Gets the parameters that will be sent to the server with each upload.

Page 24: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

22

Property Description

Settings Gets the UploadManagerSettings that will be used to configure

the C1Uploader.

UserState Gets or sets an arbitrary object that will be passed to

the UploadCompleted and UploadProgressChanged events.

See Also

Basic Methods

Basic Methods Working with Uploader for Silverlight > Basic Methods

Uploader for Silverlight includes several methods that allow you to determine what and when

files should be uploaded the control. Some of the more important methods are listed below.

The following methods let you customize the C1Uploader control:

Method Description

AddFile Adds a file to the Files collection that will be sent to the server when

the BeginUploadFiles method is invoked.

AddFiles Adds a collection of files to the Files collection that will be sent to the

server when the BeginUploadFiles method is invoked.

BeginUploadFiles Begins uploading the files specified in the Files property.

Cancel Cancels the current upload process.

See Also

Basic Events

Basic Events Working with Uploader for Silverlight > Basic Events

Uploader for Silverlight includes several events that allow you to set interaction and

customize the control. Some of the more important events are listed below.

The following events let you customize the C1Uploader control:

Page 25: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

23

Event Description

UploadCompleted Event raised when the upload has completed.

UploadProgressChanged Event that fires when the upload process makes progress.

See Also

Uploading Files

Uploading Files Working with Uploader for Silverlight > Uploading Files

The Files collection determines what files are uploaded to the server. You can add single or

multiple files to the Files collection. To add a single file to the collection, use the AddFile

method. To add multiple files use the AddFiles method. For example, you might include a

C1FilePicker control on the page and a button. When the user presses the button, the AddFile

method adds the chosen file to the Files collection.

Once you select a file or multiple files, you can use the BeginUploadFiles method to begin

uploading files to the server. When the BeginUploadFiles method is invoked, the C1Uploader

control sends files included in the Files collection to the server. If for any reason you need to

cancel the upload operation, you can invoke the Cancel method. For example, you might cancel

the operation if it takes too much time or if another operation is already in progress when the

user chooses to upload another file.

See Also

Silverlight and Local Files

Silverlight and Local Files Working with Uploader for Silverlight > Silverlight and Local Files

Silverlight limits the way that local files can be accessed on a user's machine. For security

reasons, Silverlight cannot access local files directly or access information about a user's file

system. Because of these security issues, the C1Uploader class gets access to the file stream to

upload a file using the Silverlight OpenFileDialog class.

The OpenFileDialog class returns a stream to selected files and does not give any information

about the user's file system. The OpenFileDialog class enables users to select one or more files

on the local computer or on a networked computer. Users are prompted with a dialog box

allowing them to grant access to selected files which are exposed only as file streams, similar to

isolated storage. You can use the OpenFileDialog class along with the C1Uploader class to

allow users to upload local files to the server.

Page 26: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

24

See Also

Maximum Upload Size

Maximum Upload Size Working with Uploader for Silverlight > Maximum Upload Size

You can use the C1Uploader.MaximumUploadSize property to set the maximum file size that a

user can upload to the server per upload request. Set the MaximumUploadSize property to

the maximum size per request allowed by your server. (If you are using ASP.NET, the default is

4MB.)

You can upload files larger than this size if you have C1Uploader split the file into pieces, each

of which is smaller than or equal to the MaximumUploadSize.

By default, there is no maximum upload file size, and users can upload files as large as they like,

but it can be useful to limit the size of file chunks. Large files take more time to upload, which

can cause issues where files take too long to upload or uploads time out.

To resolve these issues, configure C1Uploader to use SplitFilesIntoMultipleRequests mode.

C1Uploader splits the file into multiple requests and the MaximumUploadSize property

specifies the size of each request.

See Also

Parameters

Parameters Working with Uploader for Silverlight > Parameters

Use the Parameters property to send custom parameters from the client to the server if you

want to keep information associated with each uploaded file. For example, if you use

C1Uploader to allow users to upload music or video files, you can request information about

each file from the user to populate a database. For a music file you might request metadata that

includes the artist, title, and description.

Use the following code to set a parameter:

Visual Basic Copy Code

uploader1.Parameters("Company") = "ComponentOne"

C# Copy Code

Page 27: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

25

uploader1.Parameters["Company"] = "ComponentOne";

This adds a "Company" parameter to the uploaded file.

See Also

Uploader for Silverlight Task-Based Help

Uploader for Silverlight Samples Uploader for Silverlight includes several C# samples. By default, samples are installed in the

Documents folder in the ComponentOne Samples\Silverlight folder. The following samples

are included:

Sample Description

C1Uploader_Demo This sample demonstrates how to use the C1Uploader component. The

sample uploads files and shows the files uploaded in the server. By

default, the C1Uploader_Demo sample is installed in the

C1.Silverlight.Schedule\C1Uploader_Demo folder in the samples

directory.

UploadFiles This sample demonstrates how to use the C1Uploader component and

shows how to configure several options in the C1Uploader control. The

sample shows a step-by-step diagram of how to select files, configure

C1Uploader, call the BeginUploadFiles method, and handle the requests

on the server. By default, the UploadFiles sample is installed in the

C1.Silverlight.Schedule\UploadFiles folder in the samples directory.

Uploader for Silverlight Task-Based

Help The following task-based help topics assume that you are familiar with Visual Studio and

Expression Blend and know how to use the C1Uploader control in general. If you are unfamiliar

with the Uploader for Silverlight product, please see the Uploader for Silverlight Quick Start

first.

Each topic in this section provides a solution for specific tasks using the Uploader for

Silverlight product. Most task-based help topics also assume that you have created a new

Silverlight project.

Page 28: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

26

See Also

Splitting Files

Cancelling a File Upload

Determining whether C1Uploader is Busy

Compressing and Uploading Files

Uploading and Previewing Files

Splitting Files Uploader for Silverlight Task-Based Help > Splitting Files

Large files take more time to upload, and you may have issues where files take too long to

upload or uploads time out. You can resolve these issues by configuring C1Uploader

to SplitFilesIntoMultipleRequests mode. C1Uploader splits the file into multiple requests and

the MaximumUploadSize property specifies the size of each request.

For example, use the following code to create a new C1Uploader control that splits uploaded

files into multiple requests:

Visual Basic Copy Code

Dim uploader1 As New

C1UploaderPost(FilesPerRequest.SplitFilesIntoMultipleRequests)

C# Copy Code

C1UploaderPost uploader1 = new

C1UploaderPost(FilesPerRequest.SplitFilesIntoMultipleRequests);

C1Uploader splits uploaded files into multiple requests. Note that you can set the

MaximumUploadSize property to specify the size of each request.

See Also

Cancelling a File Upload

Page 29: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

27

Cancelling a File Upload Uploader for Silverlight Task-Based Help > Cancelling a File Upload

You may run into the need to cancel a file upload. You can use the Cancel method to cancel file

uploads. For example, you can cancel the upload if it is taking too long or using too many

resources.

For example, you might use the following code to cancel an upload:

Visual Basic Copy Code

uploader1.Cancel()

C# Copy Code

uploader1.Cancel();

This cancels the C1Uploader control's current upload process.

See Also

Determining whether C1Uploader is Busy

Determining whether C1Uploader is Busy Uploader for Silverlight Task-Based Help > Determining whether C1Uploader is Busy

Within your application, you may want to determine whether the C1Uploader control is

currently busy. You can determine whether a file is being uploaded or if C1Uploader has

finished uploading files. To do so, use the IsBusy property. The code below determines whether

the C1Uploader control is currently busy, and if not, uploads a new file.

To determine whether the uploader is busy:

Visual Basic Copy Code

If uploader.IsBusy = False Then

uploader.AddFile("test.pdf", stream)

uploader.BeginUploadFiles()

End If

Page 30: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

28

C# Copy Code

if (uploader.IsBusy == false)

{

uploader.AddFile("test.pdf", stream);

uploader.BeginUploadFiles();

}

See Also

Compressing and Uploading Files

Compressing and Uploading Files Uploader for Silverlight Task-Based Help > Compressing and Uploading Files

You may want to compress files before uploading them to the server. To do so, you can use the

C1Zip class included with Silverlight Edition along with the C1Uploader class. In this topic we

create an application to zip and upload files.

Complete the following steps to create the UI:

1. In Visual Studio 2008, select File | New | Project.

2. In the New Project dialog box, select a language in the left pane, and in the templates

list, select Silverlight Application. Enter a Name for your project and click OK. The

New Silverlight Application dialog box appears.

3. Click OK to accept default settings, close the New Silverlight Application dialog box,

and create your project. The MainPage.xaml file opens.

4. In the Solution Explorer window, right-click the project and select Add Reference.

5. In the Add Reference dialog box, locate and select the C1.Silverlight.Zip.dll and

C1.Silverlight.Uploader.dll assemblies and click OK to add references to your project.

6. Place the cursor in the XAML window of the project, and delete the <Grid> and

</Grid> tags. We replace these tags in the next step.

7. In the MainPage.xaml file, between the <UserControl> and </UserControl> tags, add

the following XAML markup:

XAML Copy Code

<StackPanel Orientation="Horizontal" x:Name="LayoutRoot" Background="White"

HorizontalAlignment="Center" VerticalAlignment="Center"

MinHeight="400">

Page 31: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

29

<Border Padding="5" BorderBrush="Black" BorderThickness="1" Margin="2"

MinWidth="200">

<StackPanel>

<Button Content="Open files" Click="OpenFiles" />

<TextBlock Text="Opened files:" FontWeight="Bold" Margin="10"/>

<ItemsControl Name="files"/>

</StackPanel>

</Border>

<Button Content="Zip and upload files >" Grid.Column="1"

VerticalAlignment="Center" Margin="10" Click="ZipAndUpload"

Name="zipAndUploladButton"/>

<Border Padding="5" BorderBrush="Black" BorderThickness="1" Margin="2"

Grid.Column="2">

<StackPanel>

<TextBlock Text="Zipped files on the server:" FontWeight="Bold"

Margin="10"/>

<ItemsControl Name="zips" Background="White"/>

</StackPanel>

</Border>

</StackPanel>

8. This markup creates panels and a button that users click to zip and upload files to the

server.

Complete the following steps to add event handling to your project:

1. In the Solution Explorer, right-click the MyProjectWeb application where "MyProject" is

the name of your project application. Select New Folder and name the folder "Zips."

This folder contains the compressed files.

2. In the Solution Explorer, right-click MainPage.xaml file and select View Code to switch

to Code view.

3. In Code view, add the following import statements to the top of the page if they are

not included:

Visual Basic Copy Code

Imports System.IO

Imports C1.C1Zip

Imports C1.Silverlight.Uploader

4.

Page 32: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

30

C# Copy Code

using System.IO;

using C1.C1Zip;

using C1.Silverlight.Uploader;

5. Define the following variables just inside the MainPage class:

Visual Basic Copy Code

Dim fileInfos As IEnumerable(Of FileInfo)

Dim zipCount As Integer = 0

6.

C# Copy Code

IEnumerable<FileInfo> fileInfos;

int zipCount = 0;

7. Below all the other methods in the MainPage class, add the following event handler to

the MainPage.xaml.cs file:

Visual Basic Copy Code

Private Sub OpenFiles(ByVal sender As Object, ByVal e As RoutedEventArgs)

Dim dialog = New OpenFileDialog()

dialog.ShowDialog()

If dialog.Files Is Nothing Then

Exit Sub

End If

fileInfos = dialog.Files

files.ItemsSource = fileInfos.[Select](Function(fi) fi.Name)

zipAndUploladButton.IsEnabled = fileInfos.Any()

End Sub

Page 33: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

31

8.

C# Copy Code

private void OpenFiles(object sender, RoutedEventArgs e)

{

var dialog = new OpenFileDialog { Multiselect = true };

dialog.ShowDialog();

if (dialog.Files == null)

{

return;

}

fileInfos = dialog.Files;

files.ItemsSource = fileInfos.Select(fi => fi.Name);

zipAndUploladButton.IsEnabled = fileInfos.Any();

}

9. This event handler initially displays an OpenFileDialog for the user to select files to

upload.

10. Add the following event handler to your project to zip and upload files:

Visual Basic Copy Code

Private Sub ZipAndUpload(ByVal sender As Object, ByVal e As

RoutedEventArgs)

' create memory stream and zip file

Dim stream = New MemoryStream()

' set MemoryThreshold to prevent C1ZipFile from trying to use a

temporary file

Dim zip = New C1ZipFile(stream, True)

' add files to zip

For Each fileInfo In fileInfos

Dim fileStream = fileInfo.OpenRead()

zip.Entries.Add(fileStream, fileInfo.Name)

fileStream.Close()

Next

Page 34: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

32

' create uploader

Dim uploader As C1Uploader = New

C1UploaderPost(BuildAbsoluteUri("Upload.ashx"))

' set the stream at the beginning and add it to the uploader

stream.Seek(0, SeekOrigin.Begin)

Dim zipName = System.Threading.Interlocked.Increment(zipCount) & ".zip"

uploader.AddFile(zipName, stream)

' when the upload is complete show it on the zips list

Dim hb As New HyperlinkButton

hb.Content = zipName

hb.NavigateUri = BuildAbsoluteUri("Zips/" + zipName)

If uploader.IsBusy = False Then

Me.zips.Items.Add(hb)

End If

' upload zip file!

uploader.BeginUploadFiles()

End Sub

11.

C# Copy Code

private void ZipAndUpload(object sender, RoutedEventArgs e)

{

// create memory stream and zip file

var stream = new MemoryStream();

var zip = new C1ZipFile(stream, true)

{

// set MemoryThreshold to prevent C1ZipFile from trying to use a

temporary file

MemoryThreshold = int.MaxValue,

CompressionLevel = CompressionLevelEnum.BestCompression

};

// add files to zip

foreach (var fileInfo in fileInfos)

{

Page 35: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

33

var fileStream = fileInfo.OpenRead();

zip.Entries.Add(fileStream, fileInfo.Name);

fileStream.Close();

}

// create uploader

C1Uploader uploader = new

C1UploaderPost(BuildAbsoluteUri("Upload.ashx"));

// set the stream at the beginning and add it to the uploader

stream.Seek(0, SeekOrigin.Begin);

var zipName = ++zipCount + ".zip";

uploader.AddFile(zipName, stream);

// when the upload is complete show it on the zips list

uploader.UploadCompleted += (s, e2) =>

{

zips.Items.Add(new HyperlinkButton

{

Content = zipName,

NavigateUri = BuildAbsoluteUri("Zips/" + zipName)

});

};

// upload zip file!

uploader.BeginUploadFiles();

}

12. Add the following event handler to your project:

Visual Basic Copy Code

Public Shared Function BuildAbsoluteUri(ByVal relativeUri As String) As Uri

' Get current absolute Uri; this depends on where the app is deployed

Dim uri As Uri = System.Windows.Browser.HtmlPage.Document.DocumentUri

Dim uriString As String = uri.AbsoluteUri

' Replace page name with relative service Uri

Dim ls As Integer = uriString.LastIndexOf("/"c)

uriString = uriString.Substring(0, ls + 1) + relativeUri

Page 36: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

34

' Return new Uri

Return New Uri(uriString, UriKind.Absolute)

End Function

13.

C# Copy Code

public static Uri BuildAbsoluteUri(string relativeUri)

{

// Get current absolute Uri; this depends on where the app is deployed

Uri uri = System.Windows.Browser.HtmlPage.Document.DocumentUri;

string uriString = uri.AbsoluteUri;

// Replace page name with relative service Uri

int ls = uriString.LastIndexOf('/');

uriString = uriString.Substring(0, ls + 1) + relativeUri;

// Return new Uri

return new Uri(uriString, UriKind.Absolute);

}

Complete the following steps to add a method to clean up and add files to the zip file:

1. In the Visual Studio Solution Explorer, right-click the MyProjectWeb solution where

"MyProject" is the name of your project. Select the Add | New Item option.

2. In the Add New Item dialog box, select the Generic Handler template and name the

new class "Upload.ashx" (this is the Uri from the C1Uploader object).

3. Click Add to add the file to your project and close the Add New Item dialog box.

4. Open the Upload.ashx code file and add the following import statement to the top of

the page if it is not included:

Visual Basic Copy Code

Imports System.Web.Services

5.

Page 37: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

35

C# Copy Code

using System.Web.Services;

6. Replace the default implementation of the ProcessRequest method with the following

code:

Visual Basic Copy Code

Sub ProcessRequest(ByVal context As HttpContext) Implements

IHttpHandler.ProcessRequest

Const MAXFILES As Integer = 30

' Clean up

Dim path As String = context.Request.MapPath("Zips")

Dim files As String() = System.IO.Directory.GetFiles(path)

If files.Length >= MAXFILES Then

For Each fileName As String In files

System.IO.File.Delete(fileName)

Next

End If

' Get files being uploaded

Dim i As Integer = 0

While i < context.Request.Files.Count AndAlso i < MAXFILES

Dim file As HttpPostedFile = context.Request.Files(i)

' Save file to the Zips folder

Dim fileName As String = context.Request.MapPath("Zips/" &

file.FileName)

file.SaveAs(fileName)

i += 1

End While

End Sub

7.

Page 38: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

36

C# Copy Code

public void ProcessRequest(HttpContext context)

{

const int MAXFILES = 30;

// Clean up

string path = context.Request.MapPath("Zips");

string[] files = System.IO.Directory.GetFiles(path);

if (files.Length >= MAXFILES)

{

foreach (string fileName in files)

System.IO.File.Delete(fileName);

}

// Get files being uploaded

for (int i = 0; i < context.Request.Files.Count && i < MAXFILES; i++)

{

HttpPostedFile file = context.Request.Files[i];

// Save file to the Zips folder

string fileName = context.Request.MapPath("Zips/" + file.FileName);

file.SaveAs(fileName);

}

}

}

8. This code starts by cleaning up the zips folder in case there are more than 30 files in it.

After the clean-up, the code loops through the files in the context.Request.Files

collection and saves each file into the Zips folder.

What You've Accomplished

You've successfully created a Silverlight application that uploads zipped files. To observe how

the application works, complete the following steps:

1. To run the application, select Debug | Start Debugging.

2. Click the Open files button to choose files to upload.

3. In the Open dialog box, select a file or multiple files to upload, and click the Open

button. The dialog box closes.

4. Click the Zip and upload files button to upload the selected files.

5. A link to the zipped file appears. (The name is "1.zip" if it is the first file uploaded.)

6. Click on the link to the zip file and save it to your computer.

7. Extract the zip file and observe that the items you uploaded exist in the file.

Page 39: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

37

See Also

Uploading and Previewing Files

Uploading and Previewing Files Uploader for Silverlight Task-Based Help > Uploading and Previewing Files

You can use Uploader for Silverlight in combination with PDF for Silverlight to create and

upload PDF files to the server. In this topic we use the C1Uploader class along with C1Pdf to

create PDF files uploaded to a stream so a user can preview files to print. Note that for

simplicity the project uses the C1UploaderHelper.cs code file included with the Uploader for

Silverlight samples.

Complete the following steps to create the project:

1. In Visual Studio 2008, select File | New | Project.

2. In the New Project dialog box, select a language in the left pane, and in the templates

list select Silverlight Application. Enter a Name for your project and click OK. The

New Silverlight Application dialog box appears.

3. Click OK to accept default settings, close the New Silverlight Application dialog box,

and create your project. The MainPage.xaml file opens.

4. Right-click the project in the Solution Explorer window and select Add Reference.

5. In the Add Reference dialog box, locate and select the C1.Silverlight.Pdf.dll and

C1.Silverlight.Uploader.dll assemblies and click OK to add references to your project.

6. in the MainPage.xaml file, between the <Grid> and </Grid> tags, add the following

XAML markup:

XAML Copy Code

<StackPanel Width="300" HorizontalAlignment="Center"

VerticalAlignment="Center">

<TextBlock Text="Enter text here:" Margin="10"/>

<TextBox Name="tb" Margin="10" Height="100" TextWrapping="Wrap"/>

<Button Content="Print and Open PDF" Margin="10" Click="Button_Click"

/>

</StackPanel>

7. This markup creates a text box to enter text to include in the PDF and a button for

users to click to turn the text into a PDF and upload the file to the server.

8. In the Solution Explorer, right-click the MyProjectWeb application where "MyProject" is

the name of your project application. Select New Folder and name the folder "temp."

This folder contains the PDF file.

Complete the following steps to code the button click and upload methods:

Page 40: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

38

1. In the Solution Explorer, right-click MainPage.xaml file and select View Code to switch

to Code view.

2. In Code view, add the following import statements to the top of the page if they are

not included:

Visual Basic Copy Code

Imports System.IO

Imports C1.Silverlight.Pdf

Imports C1.Silverlight.Uploader

3.

C# Copy Code

using System.IO;

using C1.Silverlight.Pdf;

using C1.Silverlight.Uploader;

4. Add the following code to the MainPage class:

Visual Basic Copy Code

Private Sub Button_Click(ByVal sender As Object, ByVal e As

RoutedEventArgs)

' Create PDF

Dim doc As New C1PdfDocument()

Dim st As String = Nothing

st = tb.Text

doc.DrawString(st, New Font("Arial", 14), Colors.Black, New Rect(0, 0,

500, 100))

' Generate stream

Dim stream As Stream

stream = New MemoryStream()

doc.Save(stream)

Page 41: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

39

' Upload stream

Dim uploader = CreateUploader()

uploader.AddFile("test.pdf", stream)

uploader.BeginUploadFiles()

AddHandler uploader.UploadCompleted, AddressOf uploader_UploadCompleted

End Sub

Private Sub uploader_UploadCompleted(ByVal sender As Object, ByVal e As

UploadCompletedEventArgs)

' Navigate to PDF

If e.[Error] Is Nothing Then

Dim url = New Uri(DirectCast(e.Response, String())(0))

System.Windows.Browser.HtmlPage.Window.Navigate(url)

End If

End Sub

Private Function CreateUploader() As C1Uploader

Dim mpUploader As New

C1UploaderPost(FilesPerRequest.AllFilesInOneRequest)

mpUploader.Settings.Address =

C1.Silverlight.Extensions.GetAbsoluteUri("Handler.ashx")

Return mpUploader

End Function

5.

C# Copy Code

private void Button_Click(object sender, RoutedEventArgs e)

{

// Create PDF

C1PdfDocument doc = new C1PdfDocument();

doc.DrawString(tb.Text, new Font("Arial", 12), Colors.Black, new

Rect(0, 0, 500, 100));

// Generate stream

Stream stream;

stream = new MemoryStream();

doc.Save(stream);

Page 42: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

40

// Upload stream

var uploader = CreateUploader();

uploader.AddFile("test.pdf", stream);

uploader.BeginUploadFiles();

uploader.UploadCompleted += new

EventHandler<UploadCompletedEventArgs>(uploader_UploadCompleted);

}

void uploader_UploadCompleted(object sender, UploadCompletedEventArgs e)

{

// Navigate to PDF

if (e.Error == null)

{

var url = new Uri(((string[])e.Response)[0]);

System.Windows.Browser.HtmlPage.Window.Navigate(url);

}

}

private C1Uploader CreateUploader()

{

C1UploaderPost mpUploader = new

C1UploaderPost(FilesPerRequest.AllFilesInOneRequest);

mpUploader.Settings.Address =

C1.Silverlight.Extensions.GetAbsoluteUri("Handler.ashx");

return mpUploader;

}

Complete the following steps to process requests:

1. In the Visual Studio Solution Explorer, right-click the MyProjectWeb solution where

"MyProject" is the name of your project. Select the Add | Existing Item option.

2. In the Add Existing Item dialog box, navigate to the ControlExplorerWeb folder where

samples are installed, select the C1UploaderHelper.cs file, and click the Add button.

By default the ControlExplorerWeb folder is located in the Documents or My

Documents folder at ComponentOne Samples\Studio for

Silverlight\ControlExplorer\ControlExplorerWeb.

3. In the Visual Studio Solution Explorer, right-click the MyProjectWeb solution where

"MyProject" is the name of your project. Select the Add | New Item option.

4. In the Add New Item dialog box, select the Generic Handler template and name the

new class "Handler.ashx."

5. Click Add to add the file to your project and close the Add New Item dialog box.

Page 43: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

41

6. Open the Handler.ashx code file and add the following import statement (where

"MyProject" is the name of your project application in the Solution Explorer) to the top

of the page if it is not included:

Visual Basic Copy Code

Imports System.Web

Imports System.Web.Services

Imports MyProject

7.

C# Copy Code

using System.Web;

using System.Web.Services;

using MyProject;

8. Replace the default implementation of the ProcessRequest method with the following

code:

Visual Basic Copy Code

Sub ProcessRequest(ByVal context As HttpContext) Implements

IHttpHandler.ProcessRequest

Try

' Get custom parameters

Dim parameters As String = context.Request.Params("parameters")

For i As Integer = 0 To context.Request.Files.Count - 1

' Get the uploaded file, and calculates the full path to save it in

the server

Dim file As HttpPostedFile = context.Request.Files(i)

Dim serverFileName As String =

C1UploaderHelper.GetServerPath(context.Server, file.FileName)

If C1UploaderHelper.ProcessPart(context, file.InputStream,

serverFileName, 1, 1) Then

Page 44: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

42

' Add the URL of the uploaded file to the response

Dim url As String =

C1UploaderHelper.GetUploadedFileUrl(context, "Handler.ashx",file.FileName)

context.Response.Write((If(i > 0, "|", String.Empty)) + url)

Else

C1UploaderHelper.WriteError(context,

C1UploaderHelper.ERROR_MESSAGE)

Exit For

End If

Next

Catch exc As Exception

C1UploaderHelper.WriteError(context, exc.Message)

context.Response.[End]()

End Try

End Sub

9.

C# Copy Code

public void ProcessRequest(HttpContext context)

{

try

{

// Get custom parameters

string parameters = context.Request.Params["parameters"];

for (int i = 0; i < context.Request.Files.Count; i++)

{

// Get the uploaded file, and calculates the full path to save

it in the server

HttpPostedFile file = context.Request.Files[i];

string serverFileName =

C1UploaderHelper.GetServerPath(context.Server,file.FileName);

if (File.Exists(file.FileName))

File.Delete(file.FileName);

if (C1UploaderHelper.ProcessPart(context, file.InputStream,

serverFileName, 1, 1))

{

// Add the URL of the uploaded file to the response

Page 45: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

43

string url =

C1UploaderHelper.GetUploadedFileUrl(context,"Handler.ashx", file.FileName);

context.Response.Write((i > 0 ? "|" : string.Empty) + url);

}

else

{

C1UploaderHelper.WriteError(context,

C1UploaderHelper.ERROR_MESSAGE);

break;

}

}

}

catch (Exception exc)

{

C1UploaderHelper.WriteError(context, exc.Message);

context.Response.End();

}

}

What You've Accomplished

You've successfully created a Silverlight application that uploads and previews text in a PDF file.

To observe how the application works, complete the following steps:

1. To run the application, select Debug | Start Debugging.

2. Enter text in the text box, for example "Hello World!"

3. Click the Print and Open PDF button.

The text you entered is added to the test.pdf file and opened. You can close the PDF file, enter

new text in the text box, and click the button. The new text appears in the PDF file that opens.

See Also

C1.Silverlight.Uploader Namespace

Page 46: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

44

API

C1.Silverlight.Uploader.5 Assembly

Namespaces

C1.Silverlight.Uploader Namespace

Overview Classes

Class Description

C1Uploader Represents an object that uploads files to a

server.

C1UploaderPost Represents a class that uploads files to the

server using multipart POST messages.

C1UploaderWebService Represents a class that uploads files to the

server using Web services.

FilePackager Represents an object that maps files into server

requests.

FilePackagerFactory Static class that creates FilePackager objects.

FilePackagerMultiFile FilePackager that packages multiple files per

request.

FilePackagerPartialFile FilePackager that breaks up files into multiple

requests.

FilePackagerSingleFile FilePackager that packages one file per request.

InvalidAddressException This exception is raised if the address of the

service to be called is not correct.

Page 47: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

45

MaximumUploadSizeExceededException This exception is raised when the size needed to

do the upload is greater than the size specified

by the user.

MIMETypeRequestedEventArgs Provides data for the

C1UploaderPost.MIMETypeRequested event.

UploadCompletedEventArgs Contains data about upload completed event of

the upload file

UploadFileInfo Wraps the information of files that comes from

different sources.

UploadFilePartInfo Represents a file part. It can be a file or a file

segment.

UploadFilePartPackage Contains a sets of UploadFilePartInfo.

UploadManagerPost Class that packages files into multipart POST

requests.

UploadManagerSettings Contains parameters that specify the behavior of

IUploadManager objects.

UploadManagerSettingsPost Contains parameters that specify the behavior of

UploadManagerPost objects.

UploadManagerSettingsWebService Contains parameters that specify the behavior of

UploadManagerWebService objects.

UploadManagerWebService Class that packages files into Web Service

requests.

UploadProgressChangedEventArgs Contains data about progress changed event of

the upload file.

Interfaces

Interface Description

Page 48: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

46

IUploadManager Interface implemented by classes that package files into server requests.

Delegates

Delegate Description

C1UploaderPost.MIMETypeRequestedEventHandle

r

Represents the method that will

handle the

C1UploaderPost.MIMETypeRequeste

d event.

Enumerations

Enumeration Description

FilesPerRequest Specifies how files are mapped into server requests.

MultipartPostEncoding Specifies the encoding of the data that will be sent in the post

message.

See Also

Reference

C1.Silverlight.Uploader.5 Assembly

Classes

C1Uploader Represents an object that uploads files to a server.

Object Model

Syntax

Visual Basic (Declaration)

Public MustInherit Class C1Uploader

C#

public abstract class C1Uploader

Remarks

Page 49: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

47

C1Uploader is the abstract base class of C1UploaderPost, which uploads files using multipart

POST requests, and C1UploaderWebService, which uploads files using web services.

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.C1Uploader

C1.Silverlight.Uploader.C1UploaderPost

C1.Silverlight.Uploader.C1UploaderWebService

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1Uploader Members

C1.Silverlight.Uploader Namespace

Overview Represents an object that uploads files to a server.

Object Model

Syntax

Visual Basic (Declaration)

Public MustInherit Class C1Uploader

C#

public abstract class C1Uploader

Remarks

C1Uploader is the abstract base class of C1UploaderPost, which uploads files using multipart

POST requests, and C1UploaderWebService, which uploads files using web services.

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.C1Uploader

C1.Silverlight.Uploader.C1UploaderPost

C1.Silverlight.Uploader.C1UploaderWebService

Page 50: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

48

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1Uploader Members

C1.Silverlight.Uploader Namespace

Members Properties Methods Events

The following tables list the members exposed by C1Uploader.

Public Properties

Name Description

Files Gets the collection of files that will be uploaded.

Headers Gets the headers that will be sent to the server with each upload.

IsBusy Gets whether the component is currently uploading files.

MaximumUploadSize Gets or sets the maximum size in bytes allowed for each upload.

Parameters Gets the parameters that will be sent to the server with each

upload.

Settings Gets the UploadManagerSettings that will be used to configure the

C1Uploader.

UserState Gets or sets an arbitrary object that will be passed to the

UploadCompleted and UploadProgressChanged events.

Top

Public Methods

Name Description

Page 51: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

49

AddFile Overloaded. Adds a file to the Files collection that will be sent to the

server when the BeginUploadFiles method is invoked.

AddFiles Adds a collection of files to the Files collection that will be sent to the

server when the BeginUploadFiles method is invoked.

BeginUploadFiles Begins uploading the files specified in the Files property.

Cancel Cancels the current upload process.

Top

Public Events

Name Description

UploadCompleted Event raised when the upload has completed.

UploadProgressChanged Event that fires when the upload process makes progress.

Top

See Also

Reference

C1Uploader Class

C1.Silverlight.Uploader Namespace

Methods %%scrap%%

" -->

For a list of all members of this type, see C1Uploader members.

Public Methods

Name Description

AddFile Overloaded. Adds a file to the Files collection that will be sent to the

server when the BeginUploadFiles method is invoked.

AddFiles Adds a collection of files to the Files collection that will be sent to the

server when the BeginUploadFiles method is invoked.

Page 52: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

50

BeginUploadFiles Begins uploading the files specified in the Files property.

Cancel Cancels the current upload process.

Top

See Also

Reference

C1Uploader Class

C1.Silverlight.Uploader Namespace

AddFile Method Adds a file to the Files collection that will be sent to the server when the BeginUploadFiles

method is invoked.

Overload List

Overload Description

AddFile(FileInfo) Adds a file to the Files collection that will be sent to the server when

the BeginUploadFiles method is invoked.

AddFile(String) Adds a file to the Files collection that will be sent to the server when

the BeginUploadFiles method is invoked.

AddFile(String,Stream) Adds a System.IO.Stream to the Files collection that will be sent to

the server when the BeginUploadFiles method is invoked.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1Uploader Class

C1Uploader Members

AddFile(FileInfo) Method

System.IO.FileInfo that identifies the file to be uploaded.

Adds a file to the Files collection that will be sent to the server when the BeginUploadFiles

method is invoked.

Page 53: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

51

Syntax

Visual Basic (Declaration)

Public Overloads Sub AddFile( _

ByVal file As System.IO.FileInfo _

)

C#

public void AddFile(

System.IO.FileInfo file

)

Parameters

file

System.IO.FileInfo that identifies the file to be uploaded.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows

Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported

with SP1 or later), Windows Server 2003 SP2

See Also

Reference

C1Uploader Class

C1Uploader Members

Overload List

AddFile(String) Method

Name of the file (in the Silverlight Isolated Storage) to be uploaded.

Adds a file to the Files collection that will be sent to the server when the BeginUploadFiles

method is invoked.

Syntax

Visual Basic (Declaration)

Public Overloads Sub AddFile( _

ByVal fileName As System.String _

)

C#

public void AddFile(

Page 54: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

52

System.string fileName

)

Parameters

fileName

Name of the file (in the Silverlight Isolated Storage) to be uploaded.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows

Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported

with SP1 or later), Windows Server 2003 SP2

See Also

Reference

C1Uploader Class

C1Uploader Members

Overload List

AddFile(String,Stream) Method

Name of the file as it will be seen by the server.

System.IO.Stream that contains the data to be uploaded.

Adds a System.IO.Stream to the Files collection that will be sent to the server when the

BeginUploadFiles method is invoked.

Syntax

Visual Basic (Declaration)

Public Overloads Sub AddFile( _

ByVal name As System.String, _

ByVal file As System.IO.Stream _

)

C#

public void AddFile(

System.string name,

System.IO.Stream file

)

Parameters

name

Name of the file as it will be seen by the server.

Page 55: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

53

file

System.IO.Stream that contains the data to be uploaded.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3,

Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server

Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

C1Uploader Class

C1Uploader Members

Overload List

AddFiles Method Collection of System.IO.FileInfo objects that specify the files to be uploaded.

Adds a collection of files to the Files collection that will be sent to the server when the

BeginUploadFiles method is invoked.

Syntax

Visual Basic (Declaration)

Public Sub AddFiles( _

ByVal files As System.Collections.Generic.IEnumerable(Of FileInfo) _

)

C#

public void AddFiles(

System.Collections.Generic.IEnumerable<FileInfo> files

)

Parameters

files

Collection of System.IO.FileInfo objects that specify the files to be uploaded.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows

Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported

with SP1 or later), Windows Server 2003 SP2

See Also

Page 56: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

54

Reference

C1Uploader Class

C1Uploader Members

BeginUploadFiles Method Begins uploading the files specified in the Files property.

Syntax

Visual Basic (Declaration)

Public Function BeginUploadFiles() As System.Boolean

C#

public System.bool BeginUploadFiles()

Return Value

True if the upload started successfully, false if the C1Uploader is busy or if there are no files to

upload.

Exceptions

Exception Description

MaximumUploadSizeExceededException This exception is raised when the size needed to do

the upload is greater than the size specified by the

user.

InvalidAddressException This exception is raised if the address of the service

to be called is not correct.

Remarks

You can check the IsBusy property to determine whether the component is currently uploading

files, and use the Cancel method to cancel the current upload process.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

Page 57: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

55

C1Uploader Class

C1Uploader Members

Cancel Method Cancels the current upload process.

Syntax

Visual Basic (Declaration)

Public Function Cancel() As System.Boolean

C#

public System.bool Cancel()

Return Value

True if the current upload process has been canceled successfully.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1Uploader Class

C1Uploader Members

Properties >

Name Description

Files Gets the collection of files that will be uploaded.

Headers Gets the headers that will be sent to the server with each upload.

IsBusy Gets whether the component is currently uploading files.

MaximumUploadSize Gets or sets the maximum size in bytes allowed for each upload.

Parameters Gets the parameters that will be sent to the server with each upload.

Settings

Gets the UploadManagerSettings that will be used to configure the

C1Uploader.

Page 58: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

56

UserState

Gets or sets an arbitrary object that will be passed to the

UploadCompleted and UploadProgressChanged events.

Top

See Also

Reference

C1Uploader Class

C1.Silverlight.Uploader Namespace

Files Property Gets the collection of files that will be uploaded.

Syntax

Visual Basic (Declaration)

Public ReadOnly Property Files As System.Collections.Generic.List(Of

UploadFileInfo)

C#

public System.Collections.Generic.List<UploadFileInfo> Files {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1Uploader Class

C1Uploader Members

Headers Property Gets the headers that will be sent to the server with each upload.

Syntax

Visual Basic (Declaration)

Public ReadOnly Property Headers As

System.Collections.Generic.Dictionary(Of HttpRequestHeader,String)

C#

Page 59: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

57

public System.Collections.Generic.Dictionary<HttpRequestHeader,string>

Headers {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1Uploader Class

C1Uploader Members

IsBusy Property Gets whether the component is currently uploading files.

Syntax

Visual Basic (Declaration)

Public ReadOnly Property IsBusy As System.Boolean

C#

public System.bool IsBusy {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1Uploader Class

C1Uploader Members

MaximumUploadSize Property Gets or sets the maximum size in bytes allowed for each upload.

Syntax

Visual Basic (Declaration)

Public Property MaximumUploadSize As System.Long

Page 60: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

58

C#

public System.long MaximumUploadSize {get; set;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1Uploader Class

C1Uploader Members

Parameters Property Gets the parameters that will be sent to the server with each upload.

Syntax

Visual Basic (Declaration)

Public ReadOnly Property Parameters As

System.Collections.Generic.Dictionary(Of String,String)

C#

public System.Collections.Generic.Dictionary<string,string> Parameters

{get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1Uploader Class

C1Uploader Members

Settings Property Gets the UploadManagerSettings that will be used to configure the C1Uploader.

Syntax

Page 61: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

59

Visual Basic (Declaration)

Public Overridable ReadOnly Property Settings As UploadManagerSettings

C#

public virtual UploadManagerSettings Settings {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1Uploader Class

C1Uploader Members

UserState Property Gets or sets an arbitrary object that will be passed to the UploadCompleted and

UploadProgressChanged events.

Syntax

Visual Basic (Declaration)

Public Property UserState As System.Object

C#

public System.object UserState {get; set;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1Uploader Class

C1Uploader Members

Events %%scrap%%

" -->

Page 62: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

60

For a list of all members of this type, see C1Uploader members.

Public Events

Name Description

UploadCompleted Event raised when the upload has completed.

UploadProgressChanged Event that fires when the upload process makes progress.

Top

See Also

Reference

C1Uploader Class

C1.Silverlight.Uploader Namespace

UploadCompleted Event Event raised when the upload has completed.

Syntax

Visual Basic (Declaration)

Public Event UploadCompleted As System.EventHandler(Of

UploadCompletedEventArgs)

C#

public event System.EventHandler<UploadCompletedEventArgs> UploadCompleted

Event Data

The event handler receives an argument of type UploadCompletedEventArgs containing data

related to this event. The following UploadCompletedEventArgs properties provide

information specific to this event.

Property Description

Cancelled (Inherited from System.ComponentModel.AsyncCompletedEventArgs)

Error (Inherited from System.ComponentModel.AsyncCompletedEventArgs)

Files Array of names of the files uploaded

Response Response returned by the server in the message body.

Page 63: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

61

Success True if all the files were uploaded successfully.

UserState (Inherited from System.ComponentModel.AsyncCompletedEventArgs)

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1Uploader Class

C1Uploader Members

UploadProgressChanged Event Event that fires when the upload process makes progress.

Syntax

Visual Basic (Declaration)

Public Event UploadProgressChanged As System.EventHandler(Of

UploadProgressChangedEventArgs)

C#

public event System.EventHandler<UploadProgressChangedEventArgs>

UploadProgressChanged

Event Data

The event handler receives an argument of type UploadProgressChangedEventArgs containing

data related to this event. The following UploadProgressChangedEventArgs properties

provide information specific to this event.

Property Description

BytesUploaded Amount of bytes that were uploaded.

ProgressPercentage Percentage of bytes that were uploaded.

TotalBytesToUpload Amount of bytes that must be uploaded.

UserState Additional information attached by the user.

Page 64: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

62

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1Uploader Class

C1Uploader Members

C1UploaderPost Represents a class that uploads files to the server using multipart POST messages.

Object Model

Syntax

Visual Basic (Declaration)

Public Class C1UploaderPost

Inherits C1Uploader

C#

public class C1UploaderPost : C1Uploader

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.C1Uploader

C1.Silverlight.Uploader.C1UploaderPost

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1UploaderPost Members

C1.Silverlight.Uploader Namespace

Page 65: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

63

Overview Represents a class that uploads files to the server using multipart POST messages.

Object Model

Syntax

Visual Basic (Declaration)

Public Class C1UploaderPost

Inherits C1Uploader

C#

public class C1UploaderPost : C1Uploader

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.C1Uploader

C1.Silverlight.Uploader.C1UploaderPost

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1UploaderPost Members

C1.Silverlight.Uploader Namespace

Members Properties Methods Events

The following tables list the members exposed by C1UploaderPost.

Public Constructors

Name Description

C1UploaderPost Constructor Overloaded.

Top

Page 66: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

64

Public Properties

Name Description

Files Gets the collection of files that will be uploaded. (Inherited from

C1.Silverlight.Uploader.C1Uploader)

Headers Gets the headers that will be sent to the server with each upload.

(Inherited from C1.Silverlight.Uploader.C1Uploader)

IsBusy Gets whether the component is currently uploading files. (Inherited

from C1.Silverlight.Uploader.C1Uploader)

MaximumUploadSize Gets or sets the maximum size in bytes allowed for each upload.

(Inherited from C1.Silverlight.Uploader.C1Uploader)

Parameters Gets the parameters that will be sent to the server with each

upload. (Inherited from C1.Silverlight.Uploader.C1Uploader)

Settings Gets the UploadManagerSettingsPost that specifies how the upload

process should be performed.

UserState Gets or sets an arbitrary object that will be passed to the

UploadCompleted and UploadProgressChanged events. (Inherited

from C1.Silverlight.Uploader.C1Uploader)

Top

Public Methods

Name Description

AddFile Overloaded. Adds a file to the Files collection that will be sent to the

server when the BeginUploadFiles method is invoked. (Inherited from

C1.Silverlight.Uploader.C1Uploader)

AddFiles Adds a collection of files to the Files collection that will be sent to the

server when the BeginUploadFiles method is invoked. (Inherited from

C1.Silverlight.Uploader.C1Uploader)

Page 67: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

65

BeginUploadFiles Begins uploading the files specified in the Files property. (Inherited

from C1.Silverlight.Uploader.C1Uploader)

Cancel Cancels the current upload process. (Inherited from

C1.Silverlight.Uploader.C1Uploader)

Top

Public Events

Name Description

MIMETypeRequested This event will be raised for each file, to customize the Content-

Type http header.

UploadCompleted Event raised when the upload has completed. (Inherited from

C1.Silverlight.Uploader.C1Uploader)

UploadProgressChanged Event that fires when the upload process makes progress.

(Inherited from C1.Silverlight.Uploader.C1Uploader)

Top

See Also

Reference

C1UploaderPost Class

C1.Silverlight.Uploader Namespace

C1UploaderPost Constructor

Overload List

Overload Description

C1UploaderPost Constructor(Uri) Initializes a new

instance of a

C1UploaderPost.

C1UploaderPost Constructor(FilesPerRequest) Initializes a new

instance of a

C1UploaderPost.

Page 68: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

66

C1UploaderPost Constructor(UploadManagerSettingsPost) Initializes a new

instance of a

C1UploaderPost.

C1UploaderPost Constructor(UploadManagerSettingsPost,FilePackager) Initializes a new

instance of a

C1UploaderPost.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1UploaderPost Class

C1UploaderPost Members

C1UploaderPost Constructor(Uri) System.Uri that will receive the upload requests.

Initializes a new instance of a C1UploaderPost.

Syntax

Visual Basic (Declaration)

Public Function New( _

ByVal address As System.Uri _

)

C#

public C1UploaderPost(

System.Uri address

)

Parameters

address

System.Uri that will receive the upload requests.

Requirements

Page 69: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

67

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows

Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported

with SP1 or later), Windows Server 2003 SP2

See Also

Reference

C1UploaderPost Class

C1UploaderPost Members

Overload List

C1UploaderPost Constructor(FilesPerRequest) FilesPerRequest value that specifies how files should be packaged into requests.

Initializes a new instance of a C1UploaderPost.

Syntax

Visual Basic (Declaration)

Public Function New( _

ByVal filePackager As FilesPerRequest _

)

C#

public C1UploaderPost(

FilesPerRequest filePackager

)

Parameters

filePackager

FilesPerRequest value that specifies how files should be packaged into requests.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows

Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported

with SP1 or later), Windows Server 2003 SP2

See Also

Reference

C1UploaderPost Class

C1UploaderPost Members

Overload List

Page 70: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

68

C1UploaderPost Constructor(UploadManagerSettingsPost) UploadManagerSettingsPost that specifies how the upload process will be performed.

Initializes a new instance of a C1UploaderPost.

Syntax

Visual Basic (Declaration)

Public Function New( _

ByVal settings As UploadManagerSettingsPost _

)

C#

public C1UploaderPost(

UploadManagerSettingsPost settings

)

Parameters

settings

UploadManagerSettingsPost that specifies how the upload process will be performed.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows

Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported

with SP1 or later), Windows Server 2003 SP2

See Also

Reference

C1UploaderPost Class

C1UploaderPost Members

Overload List

C1UploaderPost Constructor(UploadManagerSettingsPost,FilePackager) UploadManagerSettingsPost that specifies how the upload process will be performed.

FilesPerRequest value that specifies how files should be packaged into requests.

Initializes a new instance of a C1UploaderPost.

Syntax

Visual Basic (Declaration)

Public Function New( _

Page 71: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

69

ByVal settings As UploadManagerSettingsPost, _

ByVal filePackager As FilePackager _

)

C#

public C1UploaderPost(

UploadManagerSettingsPost settings,

FilePackager filePackager

)

Parameters

settings

UploadManagerSettingsPost that specifies how the upload process will be performed.

filePackager

FilesPerRequest value that specifies how files should be packaged into requests.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3,

Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server

Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

C1UploaderPost Class

C1UploaderPost Members

Overload List

Properties >

Name Description

Files

Gets the collection of files that will be uploaded. (Inherited from

C1.Silverlight.Uploader.C1Uploader)

Headers

Gets the headers that will be sent to the server with each upload.

(Inherited from C1.Silverlight.Uploader.C1Uploader)

IsBusy

Gets whether the component is currently uploading files. (Inherited

from C1.Silverlight.Uploader.C1Uploader)

MaximumUploadSize

Gets or sets the maximum size in bytes allowed for each upload.

(Inherited from C1.Silverlight.Uploader.C1Uploader)

Page 72: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

70

Parameters

Gets the parameters that will be sent to the server with each upload.

(Inherited from C1.Silverlight.Uploader.C1Uploader)

Settings

Gets the UploadManagerSettingsPost that specifies how the upload

process should be performed.

UserState

Gets or sets an arbitrary object that will be passed to the

UploadCompleted and UploadProgressChanged events. (Inherited

from C1.Silverlight.Uploader.C1Uploader)

Top

See Also

Reference

C1UploaderPost Class

C1.Silverlight.Uploader Namespace

Settings Property Gets the UploadManagerSettingsPost that specifies how the upload process should be

performed.

Syntax

Visual Basic (Declaration)

Public Shadows ReadOnly Property Settings As UploadManagerSettingsPost

C#

public new UploadManagerSettingsPost Settings {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1UploaderPost Class

C1UploaderPost Members

Events %%scrap%%

" -->

For a list of all members of this type, see C1UploaderPost members.

Page 73: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

71

Public Events

Name Description

MIMETypeRequested This event will be raised for each file, to customize the Content-

Type http header.

UploadCompleted Event raised when the upload has completed. (Inherited from

C1.Silverlight.Uploader.C1Uploader)

UploadProgressChanged Event that fires when the upload process makes progress.

(Inherited from C1.Silverlight.Uploader.C1Uploader)

Top

See Also

Reference

C1UploaderPost Class

C1.Silverlight.Uploader Namespace

MIMETypeRequested Event This event will be raised for each file, to customize the Content-Type http header.

Syntax

Visual Basic (Declaration)

Public Event MIMETypeRequested As

C1UploaderPost.MIMETypeRequestedEventHandler

C#

public event C1UploaderPost.MIMETypeRequestedEventHandler MIMETypeRequested

Event Data

The event handler receives an argument of type MIMETypeRequestedEventArgs containing data

related to this event. The following MIMETypeRequestedEventArgs properties provide

information specific to this event.

Property Description

FileExtension The extension requested, including the ".".

Requirements

Page 74: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

72

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1UploaderPost Class

C1UploaderPost Members

C1UploaderWebService Represents a class that uploads files to the server using Web services.

Object Model

Syntax

Visual Basic (Declaration)

Public Class C1UploaderWebService

Inherits C1Uploader

C#

public class C1UploaderWebService : C1Uploader

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.C1Uploader

C1.Silverlight.Uploader.C1UploaderWebService

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1UploaderWebService Members

C1.Silverlight.Uploader Namespace

Overview Represents a class that uploads files to the server using Web services.

Page 75: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

73

Object Model

Syntax

Visual Basic (Declaration)

Public Class C1UploaderWebService

Inherits C1Uploader

C#

public class C1UploaderWebService : C1Uploader

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.C1Uploader

C1.Silverlight.Uploader.C1UploaderWebService

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1UploaderWebService Members

C1.Silverlight.Uploader Namespace

Members Properties Methods Events

The following tables list the members exposed by C1UploaderWebService.

Public Constructors

Name Description

C1UploaderWebService Constructor Overloaded.

Top

Public Properties

Page 76: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

74

Name Description

Files Gets the collection of files that will be uploaded. (Inherited from

C1.Silverlight.Uploader.C1Uploader)

Headers Gets the headers that will be sent to the server with each upload.

(Inherited from C1.Silverlight.Uploader.C1Uploader)

IsBusy Gets whether the component is currently uploading files. (Inherited

from C1.Silverlight.Uploader.C1Uploader)

MaximumUploadSize Gets or sets the maximum size in bytes allowed for each upload.

(Inherited from C1.Silverlight.Uploader.C1Uploader)

Parameters Gets the parameters that will be sent to the server with each

upload. (Inherited from C1.Silverlight.Uploader.C1Uploader)

Settings Gets the settings that will be used by the upload algorithm to do

the uploads.

UserState Gets or sets an arbitrary object that will be passed to the

UploadCompleted and UploadProgressChanged events. (Inherited

from C1.Silverlight.Uploader.C1Uploader)

Top

Public Methods

Name Description

AddFile Overloaded. Adds a file to the Files collection that will be sent to the

server when the BeginUploadFiles method is invoked. (Inherited from

C1.Silverlight.Uploader.C1Uploader)

AddFiles Adds a collection of files to the Files collection that will be sent to the

server when the BeginUploadFiles method is invoked. (Inherited from

C1.Silverlight.Uploader.C1Uploader)

BeginUploadFiles Begins uploading the files specified in the Files property. (Inherited

from C1.Silverlight.Uploader.C1Uploader)

Page 77: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

75

Cancel Cancels the current upload process. (Inherited from

C1.Silverlight.Uploader.C1Uploader)

Top

Public Events

Name Description

UploadCompleted Event raised when the upload has completed. (Inherited from

C1.Silverlight.Uploader.C1Uploader)

UploadProgressChanged Event that fires when the upload process makes progress.

(Inherited from C1.Silverlight.Uploader.C1Uploader)

Top

See Also

Reference

C1UploaderWebService Class

C1.Silverlight.Uploader Namespace

C1UploaderWebService Constructor

Overload List

Overload Description

C1UploaderWebService Constructor(Uri) Initializes a new

instance of a

C1UploaderWebServ

ice.

C1UploaderWebService Constructor(FilesPerRequest) Initializes a new

instance of a

C1UploaderWebServ

ice.

C1UploaderWebService

Constructor(UploadManagerSettingsWebService)

Initializes a new

instance of a

C1UploaderWebServ

ice.

Page 78: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

76

C1UploaderWebService

Constructor(UploadManagerSettingsWebService,FilePackager)

Initializes a new

instance of a

C1UploaderWebServ

ice.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1UploaderWebService Class

C1UploaderWebService Members

C1UploaderWebService Constructor(Uri) Address of the service that will receive the upload

Initializes a new instance of a C1UploaderWebService.

Syntax

Visual Basic (Declaration)

Public Function New( _

ByVal address As System.Uri _

)

C#

public C1UploaderWebService(

System.Uri address

)

Parameters

address

Address of the service that will receive the upload

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows

Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported

with SP1 or later), Windows Server 2003 SP2

See Also

Page 79: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

77

Reference

C1UploaderWebService Class

C1UploaderWebService Members

Overload List

C1UploaderWebService Constructor(FilesPerRequest) Splitter mode used to upload the files

Initializes a new instance of a C1UploaderWebService.

Syntax

Visual Basic (Declaration)

Public Function New( _

ByVal splitter As FilesPerRequest _

)

C#

public C1UploaderWebService(

FilesPerRequest splitter

)

Parameters

splitter

Splitter mode used to upload the files

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows

Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported

with SP1 or later), Windows Server 2003 SP2

See Also

Reference

C1UploaderWebService Class

C1UploaderWebService Members

Overload List

C1UploaderWebService Constructor(UploadManagerSettingsWebService) Settings that will be used by the upload algorithm to do the uploads

Initializes a new instance of a C1UploaderWebService.

Syntax

Page 80: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

78

Visual Basic (Declaration)

Public Function New( _

ByVal settings As UploadManagerSettingsWebService _

)

C#

public C1UploaderWebService(

UploadManagerSettingsWebService settings

)

Parameters

settings

Settings that will be used by the upload algorithm to do the uploads

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows

Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported

with SP1 or later), Windows Server 2003 SP2

See Also

Reference

C1UploaderWebService Class

C1UploaderWebService Members

Overload List

C1UploaderWebService

Constructor(UploadManagerSettingsWebService,FilePackager) Settings that will be used by the upload algorithm to do the uploads

Initializes a new instance of a C1UploaderWebService.

Syntax

Visual Basic (Declaration)

Public Function New( _

ByVal settings As UploadManagerSettingsWebService, _

ByVal algorithm As FilePackager _

)

C#

public C1UploaderWebService(

Page 81: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

79

UploadManagerSettingsWebService settings,

FilePackager algorithm

)

Parameters

settings

Settings that will be used by the upload algorithm to do the uploads

algorithm

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3,

Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server

Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

C1UploaderWebService Class

C1UploaderWebService Members

Overload List

Properties >

Name Description

Files

Gets the collection of files that will be uploaded. (Inherited from

C1.Silverlight.Uploader.C1Uploader)

Headers

Gets the headers that will be sent to the server with each upload.

(Inherited from C1.Silverlight.Uploader.C1Uploader)

IsBusy

Gets whether the component is currently uploading files. (Inherited

from C1.Silverlight.Uploader.C1Uploader)

MaximumUploadSize

Gets or sets the maximum size in bytes allowed for each upload.

(Inherited from C1.Silverlight.Uploader.C1Uploader)

Parameters

Gets the parameters that will be sent to the server with each upload.

(Inherited from C1.Silverlight.Uploader.C1Uploader)

Settings

Gets the settings that will be used by the upload algorithm to do the

uploads.

UserState

Gets or sets an arbitrary object that will be passed to the

UploadCompleted and UploadProgressChanged events. (Inherited

from C1.Silverlight.Uploader.C1Uploader)

Page 82: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

80

Top

See Also

Reference

C1UploaderWebService Class

C1.Silverlight.Uploader Namespace

Settings Property Gets the settings that will be used by the upload algorithm to do the uploads.

Syntax

Visual Basic (Declaration)

Public Shadows ReadOnly Property Settings As

UploadManagerSettingsWebService

C#

public new UploadManagerSettingsWebService Settings {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1UploaderWebService Class

C1UploaderWebService Members

FilePackager Represents an object that maps files into server requests.

Object Model

Syntax

Visual Basic (Declaration)

Public MustInherit Class FilePackager

C#

Page 83: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

81

public abstract class FilePackager

Remarks

FilePackager is the abstract base class of FilePackagerSingleFile, which uploads one file per

request, FilePackagerMultiFile, which uploads multiple files per request, and

FilePackagerPartialFile, which uploads partial files in each request.

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.FilePackager

C1.Silverlight.Uploader.FilePackagerMultiFile

C1.Silverlight.Uploader.FilePackagerPartialFile

C1.Silverlight.Uploader.FilePackagerSingleFile

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackager Members

C1.Silverlight.Uploader Namespace

Overview Represents an object that maps files into server requests.

Object Model

Syntax

Visual Basic (Declaration)

Public MustInherit Class FilePackager

C#

public abstract class FilePackager

Remarks

FilePackager is the abstract base class of FilePackagerSingleFile, which uploads one file per

request, FilePackagerMultiFile, which uploads multiple files per request, and

FilePackagerPartialFile, which uploads partial files in each request.

Page 84: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

82

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.FilePackager

C1.Silverlight.Uploader.FilePackagerMultiFile

C1.Silverlight.Uploader.FilePackagerPartialFile

C1.Silverlight.Uploader.FilePackagerSingleFile

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackager Members

C1.Silverlight.Uploader Namespace

Members Properties Methods

The following tables list the members exposed by FilePackager.

Public Properties

Name Description

Files Gets or sets a list of files to be uploaded.

MaximumUploadSize Gets or sets the maximum size allowed per upload request.

Top

Public Methods

Name Description

GetMaxSizePerUpload Gets the maximum size needed to upload the files.

GetPackages Gets a set of packages that should be uploaded

GetTotalSize Gets the total size of all in the Files collection.

Top

See Also

Page 85: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

83

Reference

FilePackager Class

C1.Silverlight.Uploader Namespace

Methods %%scrap%%

" -->

For a list of all members of this type, see FilePackager members.

Public Methods

Name Description

GetMaxSizePerUpload Gets the maximum size needed to upload the files.

GetPackages Gets a set of packages that should be uploaded

GetTotalSize Gets the total size of all in the Files collection.

Top

See Also

Reference

FilePackager Class

C1.Silverlight.Uploader Namespace

GetMaxSizePerUpload Method Gets the maximum size needed to upload the files.

Syntax

Visual Basic (Declaration)

Public MustOverride Function GetMaxSizePerUpload() As System.Long

C#

public abstract System.long GetMaxSizePerUpload()

Return Value

Maximum size needed to upload the files

Requirements

Page 86: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

84

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackager Class

FilePackager Members

GetPackages Method Gets a set of packages that should be uploaded

Syntax

Visual Basic (Declaration)

Public MustOverride Function GetPackages() As

System.Collections.Generic.IEnumerable(Of UploadFilePartPackage)

C#

public abstract

System.Collections.Generic.IEnumerable<UploadFilePartPackage> GetPackages()

Return Value

Set of packages that should be uploaded

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackager Class

FilePackager Members

GetTotalSize Method Gets the total size of all in the Files collection.

Syntax

Visual Basic (Declaration)

Public Function GetTotalSize() As System.Long

Page 87: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

85

C#

public System.long GetTotalSize()

Return Value

Amount of size of all files

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackager Class

FilePackager Members

Properties >

Name Description

Files Gets or sets a list of files to be uploaded.

MaximumUploadSize Gets or sets the maximum size allowed per upload request.

Top

See Also

Reference

FilePackager Class

C1.Silverlight.Uploader Namespace

Files Property Gets or sets a list of files to be uploaded.

Syntax

Visual Basic (Declaration)

Public Property Files As System.Collections.Generic.List(Of UploadFileInfo)

C#

public System.Collections.Generic.List<UploadFileInfo> Files {get; set;}

Requirements

Page 88: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

86

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackager Class

FilePackager Members

MaximumUploadSize Property Gets or sets the maximum size allowed per upload request.

Syntax

Visual Basic (Declaration)

Public Property MaximumUploadSize As System.Long

C#

public System.long MaximumUploadSize {get; set;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackager Class

FilePackager Members

FilePackagerFactory Static class that creates FilePackager objects.

Object Model

Syntax

Visual Basic (Declaration)

Public MustInherit NotInheritable Class FilePackagerFactory

Page 89: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

87

C#

public static class FilePackagerFactory

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.FilePackagerFactory

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackagerFactory Members

C1.Silverlight.Uploader Namespace

Overview Static class that creates FilePackager objects.

Object Model

Syntax

Visual Basic (Declaration)

Public MustInherit NotInheritable Class FilePackagerFactory

C#

public static class FilePackagerFactory

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.FilePackagerFactory

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Page 90: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

88

Reference

FilePackagerFactory Members

C1.Silverlight.Uploader Namespace

Members Methods

The following tables list the members exposed by FilePackagerFactory.

Public Methods

Name Description

Create Creates FilePackager objects.

Top

See Also

Reference

FilePackagerFactory Class

C1.Silverlight.Uploader Namespace

Methods %%scrap%%

" -->

For a list of all members of this type, see FilePackagerFactory members.

Public Methods

Name Description

Create Creates FilePackager objects.

Top

See Also

Reference

FilePackagerFactory Class

C1.Silverlight.Uploader Namespace

Create Method FilesPerRequest value that specifies the type of FilePackager to create.

Creates FilePackager objects.

Page 91: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

89

Syntax

Visual Basic (Declaration)

Public Shared Function Create( _

ByVal mode As FilesPerRequest _

) As FilePackager

C#

public static FilePackager Create(

FilesPerRequest mode

)

Parameters

mode

FilesPerRequest value that specifies the type of FilePackager to create.

Return Value

A new FilePackager object.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows

Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported

with SP1 or later), Windows Server 2003 SP2

See Also

Reference

FilePackagerFactory Class

FilePackagerFactory Members

FilePackagerMultiFile FilePackager that packages multiple files per request.

Object Model

Syntax

Visual Basic (Declaration)

Public Class FilePackagerMultiFile

Inherits FilePackager

Page 92: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

90

C#

public class FilePackagerMultiFile : FilePackager

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.FilePackager

C1.Silverlight.Uploader.FilePackagerMultiFile

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackagerMultiFile Members

C1.Silverlight.Uploader Namespace

Overview FilePackager that packages multiple files per request.

Object Model

Syntax

Visual Basic (Declaration)

Public Class FilePackagerMultiFile

Inherits FilePackager

C#

public class FilePackagerMultiFile : FilePackager

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.FilePackager

C1.Silverlight.Uploader.FilePackagerMultiFile

Requirements

Page 93: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

91

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackagerMultiFile Members

C1.Silverlight.Uploader Namespace

Members Properties Methods

The following tables list the members exposed by FilePackagerMultiFile.

Public Constructors

Name Description

FilePackagerMultiFile Constructor Initializes a new instance of a FilePackagerMultiFile.

Top

Public Properties

Name Description

Files Gets or sets a list of files to be uploaded. (Inherited from

C1.Silverlight.Uploader.FilePackager)

MaximumUploadSize Gets or sets the maximum size allowed per upload request.

(Inherited from C1.Silverlight.Uploader.FilePackager)

Top

Public Methods

Name Description

GetMaxSizePerUpload Overridden. Gets the maximum amount of size needed to upload

the files

GetPackages Overridden. Gets a set of packages that should be uploaded

Page 94: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

92

GetTotalSize Gets the total size of all in the Files collection. (Inherited from

C1.Silverlight.Uploader.FilePackager)

Top

See Also

Reference

FilePackagerMultiFile Class

C1.Silverlight.Uploader Namespace

FilePackagerMultiFile Constructor Initializes a new instance of a FilePackagerMultiFile.

Syntax

Visual Basic (Declaration)

Public Function New()

C#

public FilePackagerMultiFile()

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackagerMultiFile Class

FilePackagerMultiFile Members

Methods >

Name Description

GetMaxSizePerUpload

Overridden. Gets the maximum amount of size needed to upload

the files

GetPackages Overridden. Gets a set of packages that should be uploaded

GetTotalSize

Gets the total size of all in the Files collection. (Inherited from

C1.Silverlight.Uploader.FilePackager)

Page 95: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

93

Top

See Also

Reference

FilePackagerMultiFile Class

C1.Silverlight.Uploader Namespace

GetMaxSizePerUpload Method Gets the maximum amount of size needed to upload the files

Syntax

Visual Basic (Declaration)

Public Overrides Function GetMaxSizePerUpload() As System.Long

C#

public override System.long GetMaxSizePerUpload()

Return Value

Maximum amount of size needed to upload the files

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackagerMultiFile Class

FilePackagerMultiFile Members

GetPackages Method Gets a set of packages that should be uploaded

Syntax

Visual Basic (Declaration)

Public Overrides Function GetPackages() As

System.Collections.Generic.IEnumerable(Of UploadFilePartPackage)

C#

Page 96: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

94

public override

System.Collections.Generic.IEnumerable<UploadFilePartPackage> GetPackages()

Return Value

Set of packages that should be uploaded

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackagerMultiFile Class

FilePackagerMultiFile Members

FilePackagerPartialFile FilePackager that breaks up files into multiple requests.

Object Model

Syntax

Visual Basic (Declaration)

Public Class FilePackagerPartialFile

Inherits FilePackager

C#

public class FilePackagerPartialFile : FilePackager

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.FilePackager

C1.Silverlight.Uploader.FilePackagerPartialFile

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Page 97: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

95

Reference

FilePackagerPartialFile Members

C1.Silverlight.Uploader Namespace

Overview FilePackager that breaks up files into multiple requests.

Object Model

Syntax

Visual Basic (Declaration)

Public Class FilePackagerPartialFile

Inherits FilePackager

C#

public class FilePackagerPartialFile : FilePackager

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.FilePackager

C1.Silverlight.Uploader.FilePackagerPartialFile

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackagerPartialFile Members

C1.Silverlight.Uploader Namespace

Members Properties Methods

The following tables list the members exposed by FilePackagerPartialFile.

Public Constructors

Name Description

Page 98: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

96

FilePackagerPartialFile Constructor Initializes a new instance of a FilePackagerPartialFile.

Top

Public Properties

Name Description

Files Gets or sets a list of files to be uploaded. (Inherited from

C1.Silverlight.Uploader.FilePackager)

MaximumUploadSize Gets or sets the maximum size allowed per upload request.

(Inherited from C1.Silverlight.Uploader.FilePackager)

Top

Public Methods

Name Description

GetMaxSizePerUpload Overridden. Gets the size needed to upload the files.

GetPackages Overridden. Gets a set of packages that should be uploaded.

GetTotalSize Gets the total size of all in the Files collection. (Inherited from

C1.Silverlight.Uploader.FilePackager)

Top

See Also

Reference

FilePackagerPartialFile Class

C1.Silverlight.Uploader Namespace

FilePackagerPartialFile Constructor Initializes a new instance of a FilePackagerPartialFile.

Syntax

Visual Basic (Declaration)

Public Function New()

C#

Page 99: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

97

public FilePackagerPartialFile()

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackagerPartialFile Class

FilePackagerPartialFile Members

Methods %%scrap%%

" -->

For a list of all members of this type, see FilePackagerPartialFile members.

Public Methods

Name Description

GetMaxSizePerUpload Overridden. Gets the size needed to upload the files.

GetPackages Overridden. Gets a set of packages that should be uploaded.

GetTotalSize Gets the total size of all in the Files collection. (Inherited from

C1.Silverlight.Uploader.FilePackager)

Top

See Also

Reference

FilePackagerPartialFile Class

C1.Silverlight.Uploader Namespace

GetMaxSizePerUpload Method Gets the size needed to upload the files.

Syntax

Visual Basic (Declaration)

Public Overrides Function GetMaxSizePerUpload() As System.Long

Page 100: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

98

C#

public override System.long GetMaxSizePerUpload()

Return Value

Maximum amount of size needed to upload the files

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackagerPartialFile Class

FilePackagerPartialFile Members

GetPackages Method Gets a set of packages that should be uploaded.

Syntax

Visual Basic (Declaration)

Public Overrides Function GetPackages() As

System.Collections.Generic.IEnumerable(Of UploadFilePartPackage)

C#

public override

System.Collections.Generic.IEnumerable<UploadFilePartPackage> GetPackages()

Return Value

Set of packages that should be uploaded.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackagerPartialFile Class

FilePackagerPartialFile Members

Page 101: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

99

FilePackagerSingleFile FilePackager that packages one file per request.

Object Model

Syntax

Visual Basic (Declaration)

Public Class FilePackagerSingleFile

Inherits FilePackager

C#

public class FilePackagerSingleFile : FilePackager

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.FilePackager

C1.Silverlight.Uploader.FilePackagerSingleFile

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackagerSingleFile Members

C1.Silverlight.Uploader Namespace

Overview FilePackager that packages one file per request.

Object Model

Syntax

Visual Basic (Declaration)

Public Class FilePackagerSingleFile

Page 102: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

100

Inherits FilePackager

C#

public class FilePackagerSingleFile : FilePackager

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.FilePackager

C1.Silverlight.Uploader.FilePackagerSingleFile

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackagerSingleFile Members

C1.Silverlight.Uploader Namespace

Members Properties Methods

The following tables list the members exposed by FilePackagerSingleFile.

Public Constructors

Name Description

FilePackagerSingleFile Constructor Initializes a new instance of a FilePackagerSingleFile.

Top

Public Properties

Name Description

Files Gets or sets a list of files to be uploaded. (Inherited from

C1.Silverlight.Uploader.FilePackager)

MaximumUploadSize Gets or sets the maximum size allowed per upload request.

(Inherited from C1.Silverlight.Uploader.FilePackager)

Top

Page 103: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

101

Public Methods

Name Description

GetMaxSizePerUpload Overridden. Gets the maximum upload size needed to upload the

files.

GetPackages Overridden. Gets a set of packages that should be uploaded

GetTotalSize Gets the total size of all in the Files collection. (Inherited from

C1.Silverlight.Uploader.FilePackager)

Top

See Also

Reference

FilePackagerSingleFile Class

C1.Silverlight.Uploader Namespace

FilePackagerSingleFile Constructor Initializes a new instance of a FilePackagerSingleFile.

Syntax

Visual Basic (Declaration)

Public Function New()

C#

public FilePackagerSingleFile()

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackagerSingleFile Class

FilePackagerSingleFile Members

Methods %%scrap%%

Page 104: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

102

" -->

For a list of all members of this type, see FilePackagerSingleFile members.

Public Methods

Name Description

GetMaxSizePerUpload Overridden. Gets the maximum upload size needed to upload the

files.

GetPackages Overridden. Gets a set of packages that should be uploaded

GetTotalSize Gets the total size of all in the Files collection. (Inherited from

C1.Silverlight.Uploader.FilePackager)

Top

See Also

Reference

FilePackagerSingleFile Class

C1.Silverlight.Uploader Namespace

GetMaxSizePerUpload Method Gets the maximum upload size needed to upload the files.

Syntax

Visual Basic (Declaration)

Public Overrides Function GetMaxSizePerUpload() As System.Long

C#

public override System.long GetMaxSizePerUpload()

Return Value

Maximum amount of size needed to upload the files

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Page 105: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

103

Reference

FilePackagerSingleFile Class

FilePackagerSingleFile Members

GetPackages Method Gets a set of packages that should be uploaded

Syntax

Visual Basic (Declaration)

Public Overrides Function GetPackages() As

System.Collections.Generic.IEnumerable(Of UploadFilePartPackage)

C#

public override

System.Collections.Generic.IEnumerable<UploadFilePartPackage> GetPackages()

Return Value

Set of packages that should be uploaded

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

FilePackagerSingleFile Class

FilePackagerSingleFile Members

InvalidAddressException This exception is raised if the address of the service to be called is not correct.

Object Model

Syntax

Visual Basic (Declaration)

Public Class InvalidAddressException

Inherits System.Exception

Page 106: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

104

C#

public class InvalidAddressException : System.Exception

Inheritance Hierarchy

System.Object

System.Exception

C1.Silverlight.Uploader.InvalidAddressException

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

InvalidAddressException Members

C1.Silverlight.Uploader Namespace

Overview This exception is raised if the address of the service to be called is not correct.

Object Model

Syntax

Visual Basic (Declaration)

Public Class InvalidAddressException

Inherits System.Exception

C#

public class InvalidAddressException : System.Exception

Inheritance Hierarchy

System.Object

System.Exception

C1.Silverlight.Uploader.InvalidAddressException

Requirements

Page 107: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

105

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

InvalidAddressException Members

C1.Silverlight.Uploader Namespace

Members Properties Methods

The following tables list the members exposed by InvalidAddressException.

Public Constructors

Name Description

InvalidAddressException Constructor Overloaded.

Top

Public Properties

Name Description

Data (Inherited from System.Exception)

HelpLink (Inherited from System.Exception)

HResult (Inherited from System.Exception)

InnerException (Inherited from System.Exception)

Message (Inherited from System.Exception)

Source (Inherited from System.Exception)

StackTrace (Inherited from System.Exception)

TargetSite (Inherited from System.Exception)

Top

Public Methods

Page 108: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

106

Name Description

GetBaseException (Inherited from System.Exception)

GetObjectData (Inherited from System.Exception)

GetType (Inherited from System.Exception)

ToString (Inherited from System.Exception)

Top

See Also

Reference

InvalidAddressException Class

C1.Silverlight.Uploader Namespace

InvalidAddressException Constructor

Overload List

Overload Description

InvalidAddressException Constructor() Initializes a new instance of a

InvalidAddressException.

InvalidAddressException Constructor(Exception) Initializes a new instance of a

InvalidAddressException.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

InvalidAddressException Class

InvalidAddressException Members

InvalidAddressException Constructor() Initializes a new instance of a InvalidAddressException.

Syntax

Page 109: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

107

Visual Basic (Declaration)

Public Function New()

C#

public InvalidAddressException()

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

InvalidAddressException Class

InvalidAddressException Members

Overload List

InvalidAddressException Constructor(Exception) the exception that is the cause of the current exception

Initializes a new instance of a InvalidAddressException.

Syntax

Visual Basic (Declaration)

Public Function New( _

ByVal innerException As System.Exception _

)

C#

public InvalidAddressException(

System.Exception innerException

)

Parameters

innerException

the exception that is the cause of the current exception

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows

Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported

with SP1 or later), Windows Server 2003 SP2

Page 110: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

108

See Also

Reference

InvalidAddressException Class

InvalidAddressException Members

Overload List

MaximumUploadSizeExceededException This exception is raised when the size needed to do the upload is greater than the size specified

by the user.

Object Model

Syntax

Visual Basic (Declaration)

Public Class MaximumUploadSizeExceededException

Inherits System.Exception

C#

public class MaximumUploadSizeExceededException : System.Exception

Inheritance Hierarchy

System.Object

System.Exception

C1.Silverlight.Uploader.MaximumUploadSizeExceededException

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

MaximumUploadSizeExceededException Members

C1.Silverlight.Uploader Namespace

Overview This exception is raised when the size needed to do the upload is greater than the size specified

by the user.

Page 111: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

109

Object Model

Syntax

Visual Basic (Declaration)

Public Class MaximumUploadSizeExceededException

Inherits System.Exception

C#

public class MaximumUploadSizeExceededException : System.Exception

Inheritance Hierarchy

System.Object

System.Exception

C1.Silverlight.Uploader.MaximumUploadSizeExceededException

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

MaximumUploadSizeExceededException Members

C1.Silverlight.Uploader Namespace

Members Properties Methods

The following tables list the members exposed by MaximumUploadSizeExceededException.

Public Constructors

Name Description

MaximumUploadSizeExceededException

Constructor

Initializes a new instance of a

MaximumUploadSizeExceededExceptio

n.

Top

Page 112: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

110

Public Properties

Name Description

Data (Inherited from System.Exception)

HelpLink (Inherited from System.Exception)

HResult (Inherited from System.Exception)

InnerException (Inherited from System.Exception)

Message (Inherited from System.Exception)

Source (Inherited from System.Exception)

StackTrace (Inherited from System.Exception)

TargetSite (Inherited from System.Exception)

Top

Public Methods

Name Description

GetBaseException (Inherited from System.Exception)

GetObjectData (Inherited from System.Exception)

GetType (Inherited from System.Exception)

ToString (Inherited from System.Exception)

Top

See Also

Reference

MaximumUploadSizeExceededException Class

C1.Silverlight.Uploader Namespace

MaximumUploadSizeExceededException Constructor Initializes a new instance of a MaximumUploadSizeExceededException.

Page 113: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

111

Syntax

Visual Basic (Declaration)

Public Function New()

C#

public MaximumUploadSizeExceededException()

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

MaximumUploadSizeExceededException Class

MaximumUploadSizeExceededException Members

MIMETypeRequestedEventArgs Provides data for the C1UploaderPost.MIMETypeRequested event.

Object Model

Syntax

Visual Basic (Declaration)

Public Class MIMETypeRequestedEventArgs

Inherits System.EventArgs

C#

public class MIMETypeRequestedEventArgs : System.EventArgs

Inheritance Hierarchy

System.Object

System.EventArgs

C1.Silverlight.Uploader.MIMETypeRequestedEventArgs

Requirements

Page 114: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

112

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

MIMETypeRequestedEventArgs Members

C1.Silverlight.Uploader Namespace

Overview Provides data for the C1UploaderPost.MIMETypeRequested event.

Object Model

Syntax

Visual Basic (Declaration)

Public Class MIMETypeRequestedEventArgs

Inherits System.EventArgs

C#

public class MIMETypeRequestedEventArgs : System.EventArgs

Inheritance Hierarchy

System.Object

System.EventArgs

C1.Silverlight.Uploader.MIMETypeRequestedEventArgs

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

MIMETypeRequestedEventArgs Members

C1.Silverlight.Uploader Namespace

Members Properties

Page 115: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

113

The following tables list the members exposed by MIMETypeRequestedEventArgs.

Public Properties

Name Description

FileExtension The extension requested, including the ".".

Top

See Also

Reference

MIMETypeRequestedEventArgs Class

C1.Silverlight.Uploader Namespace

Properties >

Name Description

FileExtension The extension requested, including the ".".

Top

See Also

Reference

MIMETypeRequestedEventArgs Class

C1.Silverlight.Uploader Namespace

FileExtension Property The extension requested, including the ".".

Syntax

Visual Basic (Declaration)

Public ReadOnly Property FileExtension As System.String

C#

public System.string FileExtension {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

Page 116: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

114

See Also

Reference

MIMETypeRequestedEventArgs Class

MIMETypeRequestedEventArgs Members

UploadCompletedEventArgs Contains data about upload completed event of the upload file

Object Model

Syntax

Visual Basic (Declaration)

Public Class UploadCompletedEventArgs

Inherits System.ComponentModel.AsyncCompletedEventArgs

C#

public class UploadCompletedEventArgs :

System.ComponentModel.AsyncCompletedEventArgs

Inheritance Hierarchy

System.Object

System.EventArgs

System.ComponentModel.AsyncCompletedEventArgs

C1.Silverlight.Uploader.UploadCompletedEventArgs

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadCompletedEventArgs Members

C1.Silverlight.Uploader Namespace

Overview Contains data about upload completed event of the upload file

Object Model

Page 117: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

115

Syntax

Visual Basic (Declaration)

Public Class UploadCompletedEventArgs

Inherits System.ComponentModel.AsyncCompletedEventArgs

C#

public class UploadCompletedEventArgs :

System.ComponentModel.AsyncCompletedEventArgs

Inheritance Hierarchy

System.Object

System.EventArgs

System.ComponentModel.AsyncCompletedEventArgs

C1.Silverlight.Uploader.UploadCompletedEventArgs

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadCompletedEventArgs Members

C1.Silverlight.Uploader Namespace

Members Properties

The following tables list the members exposed by UploadCompletedEventArgs.

Public Constructors

Name Description

UploadCompletedEventArgs Constructor Initializes a new instance of a

UploadCompletedEventArgs.

Top

Public Properties

Page 118: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

116

Name Description

Cancelled (Inherited from System.ComponentModel.AsyncCompletedEventArgs)

Error (Inherited from System.ComponentModel.AsyncCompletedEventArgs)

Files Array of names of the files uploaded

Response Response returned by the server in the message body.

Success True if all the files were uploaded successfully.

UserState (Inherited from System.ComponentModel.AsyncCompletedEventArgs)

Top

See Also

Reference

UploadCompletedEventArgs Class

C1.Silverlight.Uploader Namespace

UploadCompletedEventArgs Constructor True if all the files were uploaded successfully

True if the user cancelled the request

Exception returned if something was wrong

Array of names of the files uploaded

Response returned by the server in the message body

Additional information attached by the user

Initializes a new instance of a UploadCompletedEventArgs.

Syntax

Visual Basic (Declaration)

Public Function New( _

ByVal success As System.Boolean, _

ByVal cancelled As System.Boolean, _

ByVal error As System.Exception, _

ByVal files() As System.String, _

ByVal response As System.Object, _

Page 119: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

117

ByVal userState As System.Object _

)

C#

public UploadCompletedEventArgs(

System.bool success,

System.bool cancelled,

System.Exception error,

System.string[] files,

System.object response,

System.object userState

)

Parameters

success

True if all the files were uploaded successfully

cancelled

True if the user cancelled the request

error

Exception returned if something was wrong

files

Array of names of the files uploaded

response

Response returned by the server in the message body

userState

Additional information attached by the user

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later,

Windows XP SP3, Windows Server 2008 (Server Core not

supported), Windows Server 2008 R2 (Server Core supported

with SP1 or later), Windows Server 2003 SP2

See Also

Reference

UploadCompletedEventArgs Class

UploadCompletedEventArgs Members

Page 120: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

118

Properties >

Name Description

Cancelled (Inherited from System.ComponentModel.AsyncCompletedEventArgs)

Error (Inherited from System.ComponentModel.AsyncCompletedEventArgs)

Files Array of names of the files uploaded

Response Response returned by the server in the message body.

Success True if all the files were uploaded successfully.

UserState (Inherited from System.ComponentModel.AsyncCompletedEventArgs)

Top

See Also

Reference

UploadCompletedEventArgs Class

C1.Silverlight.Uploader Namespace

Files Property Array of names of the files uploaded

Syntax

Visual Basic (Declaration)

Public ReadOnly Property Files As System.String()

C#

public System.string[] Files {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadCompletedEventArgs Class

UploadCompletedEventArgs Members

Page 121: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

119

Response Property Response returned by the server in the message body.

Syntax

Visual Basic (Declaration)

Public ReadOnly Property Response As System.Object

C#

public System.object Response {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadCompletedEventArgs Class

UploadCompletedEventArgs Members

Success Property True if all the files were uploaded successfully.

Syntax

Visual Basic (Declaration)

Public ReadOnly Property Success As System.Boolean

C#

public System.bool Success {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadCompletedEventArgs Class

UploadCompletedEventArgs Members

Page 122: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

120

UploadFileInfo Wraps the information of files that comes from different sources.

Object Model

Syntax

Visual Basic (Declaration)

Public Class UploadFileInfo

C#

public class UploadFileInfo

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.UploadFileInfo

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFileInfo Members

C1.Silverlight.Uploader Namespace

Overview Wraps the information of files that comes from different sources.

Object Model

Syntax

Visual Basic (Declaration)

Public Class UploadFileInfo

C#

Page 123: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

121

public class UploadFileInfo

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.UploadFileInfo

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFileInfo Members

C1.Silverlight.Uploader Namespace

Members Properties Methods

The following tables list the members exposed by UploadFileInfo.

Public Constructors

Name Description

UploadFileInfo Constructor Overloaded.

Top

Public Properties

Name Description

File Data of the file.

Name Name of the file.

Top

Public Methods

Name Description

Close Closes the file if it is opened.

Page 124: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

122

GetSize Gets the size in bytes of a file.

Prepare Opens the file if it is not opened.

Top

See Also

Reference

UploadFileInfo Class

C1.Silverlight.Uploader Namespace

UploadFileInfo Constructor

Overload List

Overload Description

UploadFileInfo Constructor(FileInfo) Initializes a new instance of a UploadFileInfo.

UploadFileInfo Constructor(String) Initializes a new instance of a UploadFileInfo.

UploadFileInfo Constructor(String,Stream) Initializes a new instance of a UploadFileInfo.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFileInfo Class

UploadFileInfo Members

UploadFileInfo Constructor(FileInfo) File that comes from System.Windows.Controls.OpenFileDialog

Initializes a new instance of a UploadFileInfo.

Syntax

Visual Basic (Declaration)

Public Function New( _

ByVal file As System.IO.FileInfo _

Page 125: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

123

)

C#

public UploadFileInfo(

System.IO.FileInfo file

)

Parameters

file

File that comes from System.Windows.Controls.OpenFileDialog

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows

Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported

with SP1 or later), Windows Server 2003 SP2

See Also

Reference

UploadFileInfo Class

UploadFileInfo Members

Overload List

UploadFileInfo Constructor(String) Name of the file in the Isolated Storage

Initializes a new instance of a UploadFileInfo.

Syntax

Visual Basic (Declaration)

Public Function New( _

ByVal fileName As System.String _

)

C#

public UploadFileInfo(

System.string fileName

)

Parameters

fileName

Name of the file in the Isolated Storage

Page 126: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

124

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows

Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported

with SP1 or later), Windows Server 2003 SP2

See Also

Reference

UploadFileInfo Class

UploadFileInfo Members

Overload List

UploadFileInfo Constructor(String,Stream) Name of the file

Stream that contains the data of the file

Initializes a new instance of a UploadFileInfo.

Syntax

Visual Basic (Declaration)

Public Function New( _

ByVal name As System.String, _

ByVal file As System.IO.Stream _

)

C#

public UploadFileInfo(

System.string name,

System.IO.Stream file

)

Parameters

name

Name of the file

file

Stream that contains the data of the file

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3,

Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server

Core supported with SP1 or later), Windows Server 2003 SP2

Page 127: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

125

See Also

Reference

UploadFileInfo Class

UploadFileInfo Members

Overload List

Methods %%scrap%%

" -->

For a list of all members of this type, see UploadFileInfo members.

Public Methods

Name Description

Close Closes the file if it is opened.

GetSize Gets the size in bytes of a file.

Prepare Opens the file if it is not opened.

Top

See Also

Reference

UploadFileInfo Class

C1.Silverlight.Uploader Namespace

Close Method Closes the file if it is opened.

Syntax

Visual Basic (Declaration)

Public Sub Close()

C#

public void Close()

Requirements

Page 128: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

126

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFileInfo Class

UploadFileInfo Members

GetSize Method Gets the size in bytes of a file.

Syntax

Visual Basic (Declaration)

Public Function GetSize() As System.Long

C#

public System.long GetSize()

Return Value

Return the size in bytes of a file.

Remarks

If the Prepare method has not been called the size will be 0.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFileInfo Class

UploadFileInfo Members

Prepare Method Opens the file if it is not opened.

Syntax

Visual Basic (Declaration)

Page 129: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

127

Public Sub Prepare()

C#

public void Prepare()

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFileInfo Class

UploadFileInfo Members

Properties %%scrap%%

" -->

For a list of all members of this type, see UploadFileInfo members.

Public Properties

Name Description

File Data of the file.

Name Name of the file.

Top

See Also

Reference

UploadFileInfo Class

C1.Silverlight.Uploader Namespace

File Property Data of the file.

Syntax

Visual Basic (Declaration)

Public ReadOnly Property File As System.IO.Stream

Page 130: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

128

C#

public System.IO.Stream File {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFileInfo Class

UploadFileInfo Members

Name Property Name of the file.

Syntax

Visual Basic (Declaration)

Public ReadOnly Property Name As System.String

C#

public System.string Name {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFileInfo Class

UploadFileInfo Members

UploadFilePartInfo Represents a file part. It can be a file or a file segment.

Object Model

Syntax

Page 131: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

129

Visual Basic (Declaration)

Public Class UploadFilePartInfo

C#

public class UploadFilePartInfo

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.UploadFilePartInfo

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFilePartInfo Members

C1.Silverlight.Uploader Namespace

Overview Represents a file part. It can be a file or a file segment.

Object Model

Syntax

Visual Basic (Declaration)

Public Class UploadFilePartInfo

C#

public class UploadFilePartInfo

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.UploadFilePartInfo

Requirements

Page 132: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

130

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFilePartInfo Members

C1.Silverlight.Uploader Namespace

Members Properties Methods

The following tables list the members exposed by UploadFilePartInfo.

Public Constructors

Name Description

UploadFilePartInfo Constructor Overloaded.

Top

Public Properties

Name Description

Data Gets the data of the file part

Name Gets the name of the file part.

PartCount Gets the total number of parts associated with the owner file.

PartNumber Gets the index of a part within the owner file.

Top

Public Methods

Name Description

GetSize Gets the size of a file part.

Top

See Also

Reference

Page 133: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

131

UploadFilePartInfo Class

C1.Silverlight.Uploader Namespace

UploadFilePartInfo Constructor

Overload List

Overload Description

UploadFilePartInfo Constructor(String,Byte[],Int32,Int32) Initializes a new instance of a

UploadFilePartInfo.

UploadFilePartInfo Constructor(UploadFileInfo) Initializes a new instance of a

UploadFilePartInfo.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFilePartInfo Class

UploadFilePartInfo Members

UploadFilePartInfo Constructor(String,Byte[],Int32,Int32) Name of the file part

Data of the file part

Index of the file part in the file

Total number of parts for the file

Initializes a new instance of a UploadFilePartInfo.

Syntax

Visual Basic (Declaration)

Public Function New( _

ByVal filePartName As System.String, _

ByVal filePartData() As System.Byte, _

ByVal partNumber As System.Integer, _

ByVal partCount As System.Integer _

)

Page 134: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

132

C#

public UploadFilePartInfo(

System.string filePartName,

System.byte[] filePartData,

System.int partNumber,

System.int partCount

)

Parameters

filePartName

Name of the file part

filePartData

Data of the file part

partNumber

Index of the file part in the file

partCount

Total number of parts for the file

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP

SP3, Windows Server 2008 (Server Core not supported), Windows Server

2008 R2 (Server Core supported with SP1 or later), Windows Server 2003

SP2

See Also

Reference

UploadFilePartInfo Class

UploadFilePartInfo Members

Overload List

UploadFilePartInfo Constructor(UploadFileInfo) File that will be wrapped in a UploadFilePartInfo

Initializes a new instance of a UploadFilePartInfo.

Syntax

Visual Basic (Declaration)

Public Function New( _

ByVal file As UploadFileInfo _

Page 135: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

133

)

C#

public UploadFilePartInfo(

UploadFileInfo file

)

Parameters

file

File that will be wrapped in a UploadFilePartInfo

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows

Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported

with SP1 or later), Windows Server 2003 SP2

See Also

Reference

UploadFilePartInfo Class

UploadFilePartInfo Members

Overload List

Methods %%scrap%%

" -->

For a list of all members of this type, see UploadFilePartInfo members.

Public Methods

Name Description

GetSize Gets the size of a file part.

Top

See Also

Reference

UploadFilePartInfo Class

C1.Silverlight.Uploader Namespace

GetSize Method Gets the size of a file part.

Page 136: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

134

Syntax

Visual Basic (Declaration)

Public Function GetSize() As System.Long

C#

public System.long GetSize()

Return Value

Size of the file part.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFilePartInfo Class

UploadFilePartInfo Members

Properties >

Name Description

Data Gets the data of the file part

Name Gets the name of the file part.

PartCount Gets the total number of parts associated with the owner file.

PartNumber Gets the index of a part within the owner file.

Top

See Also

Reference

UploadFilePartInfo Class

C1.Silverlight.Uploader Namespace

Data Property Gets the data of the file part

Syntax

Page 137: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

135

Visual Basic (Declaration)

Public ReadOnly Property Data As System.Byte()

C#

public System.byte[] Data {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFilePartInfo Class

UploadFilePartInfo Members

Name Property Gets the name of the file part.

Syntax

Visual Basic (Declaration)

Public ReadOnly Property Name As System.String

C#

public System.string Name {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFilePartInfo Class

UploadFilePartInfo Members

PartCount Property Gets the total number of parts associated with the owner file.

Syntax

Page 138: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

136

Visual Basic (Declaration)

Public ReadOnly Property PartCount As System.Integer

C#

public System.int PartCount {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFilePartInfo Class

UploadFilePartInfo Members

PartNumber Property Gets the index of a part within the owner file.

Syntax

Visual Basic (Declaration)

Public ReadOnly Property PartNumber As System.Integer

C#

public System.int PartNumber {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFilePartInfo Class

UploadFilePartInfo Members

UploadFilePartPackage Contains a sets of UploadFilePartInfo.

Object Model

Page 139: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

137

Syntax

Visual Basic (Declaration)

Public Class UploadFilePartPackage

Inherits System.Collections.Generic.List(Of UploadFilePartInfo)

C#

public class UploadFilePartPackage :

System.Collections.Generic.List<UploadFilePartInfo>

Inheritance Hierarchy

System.Object

System.Collections.Generic.List<T>

C1.Silverlight.Uploader.UploadFilePartPackage

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFilePartPackage Members

C1.Silverlight.Uploader Namespace

Overview Contains a sets of UploadFilePartInfo.

Object Model

Syntax

Visual Basic (Declaration)

Public Class UploadFilePartPackage

Inherits System.Collections.Generic.List(Of UploadFilePartInfo)

C#

Page 140: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

138

public class UploadFilePartPackage :

System.Collections.Generic.List<UploadFilePartInfo>

Inheritance Hierarchy

System.Object

System.Collections.Generic.List<T>

C1.Silverlight.Uploader.UploadFilePartPackage

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFilePartPackage Members

C1.Silverlight.Uploader Namespace

Members Properties Methods

The following tables list the members exposed by UploadFilePartPackage.

Public Constructors

Name Description

UploadFilePartPackage Constructor

Top

Public Properties

Name Description

Capacity (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Count (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Item (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Page 141: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

139

ServerWaitForOneFile Gets or sets whether the package should be uploaded as a one

only file package.

Top

Public Methods

Name Description

Add (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

AddRange (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

AsReadOnly (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

BinarySearch Overloaded. (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Clear (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Contains (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

ConvertAll<TOutput> (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

CopyTo Overloaded. (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Exists (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Find (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Page 142: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

140

FindAll (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

FindIndex Overloaded. (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

FindLast (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

FindLastIndex Overloaded. (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

ForEach (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

GetEnumerator (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

GetRange (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

GetSize Gets the size of the package.

IndexOf Overloaded. (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Insert (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

InsertRange (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

LastIndexOf Overloaded. (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Remove (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Page 143: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

141

RemoveAll (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

RemoveAt (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

RemoveRange (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Reverse Overloaded. (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Sort Overloaded. (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

ToArray (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

TrimExcess (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

TrueForAll (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Top

See Also

Reference

UploadFilePartPackage Class

C1.Silverlight.Uploader Namespace

UploadFilePartPackage Constructor

Syntax

Visual Basic (Declaration)

Public Function New()

C#

public UploadFilePartPackage()

Page 144: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

142

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFilePartPackage Class

UploadFilePartPackage Members

Methods %%scrap%%

" -->

For a list of all members of this type, see UploadFilePartPackage members.

Public Methods

Name Description

Add (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

AddRange (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

AsReadOnly (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

BinarySearch Overloaded. (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Clear (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Contains (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

ConvertAll<TOutput> (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Page 145: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

143

CopyTo Overloaded. (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Exists (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Find (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

FindAll (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

FindIndex Overloaded. (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

FindLast (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

FindLastIndex Overloaded. (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

ForEach (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

GetEnumerator (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

GetRange (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

GetSize Gets the size of the package.

IndexOf Overloaded. (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Insert (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Page 146: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

144

InsertRange (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

LastIndexOf Overloaded. (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Remove (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

RemoveAll (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

RemoveAt (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

RemoveRange (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Reverse Overloaded. (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Sort Overloaded. (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

ToArray (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

TrimExcess (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

TrueForAll (Inherited from

System.Collections.Generic.List<UploadFilePartInfo>)

Top

See Also

Reference

UploadFilePartPackage Class

C1.Silverlight.Uploader Namespace

Page 147: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

145

GetSize Method Gets the size of the package.

Syntax

Visual Basic (Declaration)

Public Function GetSize() As System.Long

C#

public System.long GetSize()

Return Value

Size of the package.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFilePartPackage Class

UploadFilePartPackage Members

Properties >

Name Description

Capacity (Inherited from System.Collections.Generic.List<UploadFilePartInfo>)

Count (Inherited from System.Collections.Generic.List<UploadFilePartInfo>)

Item (Inherited from System.Collections.Generic.List<UploadFilePartInfo>)

ServerWaitForOneFile

Gets or sets whether the package should be uploaded as a one only

file package.

Top

See Also

Reference

UploadFilePartPackage Class

C1.Silverlight.Uploader Namespace

Page 148: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

146

ServerWaitForOneFile Property Gets or sets whether the package should be uploaded as a one only file package.

Syntax

Visual Basic (Declaration)

Public Property ServerWaitForOneFile As System.Boolean

C#

public System.bool ServerWaitForOneFile {get; set;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadFilePartPackage Class

UploadFilePartPackage Members

UploadManagerPost Class that packages files into multipart POST requests.

Object Model

Syntax

Visual Basic (Declaration)

Public Class UploadManagerPost

Implements IUploadManager

C#

public class UploadManagerPost : IUploadManager

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.UploadManagerPost

Requirements

Page 149: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

147

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerPost Members

C1.Silverlight.Uploader Namespace

Overview Class that packages files into multipart POST requests.

Object Model

Syntax

Visual Basic (Declaration)

Public Class UploadManagerPost

Implements IUploadManager

C#

public class UploadManagerPost : IUploadManager

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.UploadManagerPost

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerPost Members

C1.Silverlight.Uploader Namespace

Members Methods Events

The following tables list the members exposed by UploadManagerPost.

Page 150: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

148

Public Constructors

Name Description

UploadManagerPost Constructor

Top

Public Methods

Name Description

BeginUpload Begins the upload of a set of parts.

Cancel Aborts the execution of the upload.

Top

Public Events

Name Description

UploadCompleted It is raised when the upload has been completed.

UploadProgressChanged Event that fires when the upload process makes progress.

Top

See Also

Reference

UploadManagerPost Class

C1.Silverlight.Uploader Namespace

UploadManagerPost Constructor

Syntax

Visual Basic (Declaration)

Public Function New()

C#

public UploadManagerPost()

Requirements

Page 151: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

149

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerPost Class

UploadManagerPost Members

Methods >

Name Description

BeginUpload Begins the upload of a set of parts.

Cancel Aborts the execution of the upload.

Top

See Also

Reference

UploadManagerPost Class

C1.Silverlight.Uploader Namespace

BeginUpload Method Settings used to upload the part.

Package of file parts to be uploaded.

Headers that will be sent within the upload.

Parameter that will be sent to the server together with the part.

Begins the upload of a set of parts.

Syntax

Visual Basic (Declaration)

Public Function BeginUpload( _

ByVal settings As UploadManagerSettings, _

ByVal package As UploadFilePartPackage, _

ByVal headers As System.Collections.Generic.Dictionary(Of

HttpRequestHeader,String), _

ByVal parameters As System.Collections.Generic.Dictionary(Of

String,String) _

Page 152: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

150

) As System.Boolean

C#

public System.bool BeginUpload(

UploadManagerSettings settings,

UploadFilePartPackage package,

System.Collections.Generic.Dictionary<HttpRequestHeader,string> headers,

System.Collections.Generic.Dictionary<string,string> parameters

)

Parameters

settings

Settings used to upload the part.

package

Package of file parts to be uploaded.

headers

Headers that will be sent within the upload.

parameters

Parameter that will be sent to the server together with the part.

Return Value

Returns True if the upload has been started correctly.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP

SP3, Windows Server 2008 (Server Core not supported), Windows Server

2008 R2 (Server Core supported with SP1 or later), Windows Server 2003

SP2

See Also

Reference

UploadManagerPost Class

UploadManagerPost Members

Cancel Method Aborts the execution of the upload.

Syntax

Visual Basic (Declaration)

Page 153: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

151

Public Sub Cancel()

C#

public void Cancel()

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerPost Class

UploadManagerPost Members

Events %%scrap%%

" -->

For a list of all members of this type, see UploadManagerPost members.

Public Events

Name Description

UploadCompleted It is raised when the upload has been completed.

UploadProgressChanged Event that fires when the upload process makes progress.

Top

See Also

Reference

UploadManagerPost Class

C1.Silverlight.Uploader Namespace

UploadCompleted Event It is raised when the upload has been completed.

Syntax

Visual Basic (Declaration)

Page 154: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

152

Public Event UploadCompleted As System.EventHandler(Of

UploadCompletedEventArgs)

C#

public event System.EventHandler<UploadCompletedEventArgs> UploadCompleted

Event Data

The event handler receives an argument of type UploadCompletedEventArgs containing data

related to this event. The following UploadCompletedEventArgs properties provide

information specific to this event.

Property Description

Cancelled (Inherited from System.ComponentModel.AsyncCompletedEventArgs)

Error (Inherited from System.ComponentModel.AsyncCompletedEventArgs)

Files Array of names of the files uploaded

Response Response returned by the server in the message body.

Success True if all the files were uploaded successfully.

UserState (Inherited from System.ComponentModel.AsyncCompletedEventArgs)

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerPost Class

UploadManagerPost Members

UploadProgressChanged Event Event that fires when the upload process makes progress.

Syntax

Visual Basic (Declaration)

Page 155: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

153

Public Event UploadProgressChanged As System.EventHandler(Of

UploadProgressChangedEventArgs)

C#

public event System.EventHandler<UploadProgressChangedEventArgs>

UploadProgressChanged

Event Data

The event handler receives an argument of type UploadProgressChangedEventArgs containing

data related to this event. The following UploadProgressChangedEventArgs properties

provide information specific to this event.

Property Description

BytesUploaded Amount of bytes that were uploaded.

ProgressPercentage Percentage of bytes that were uploaded.

TotalBytesToUpload Amount of bytes that must be uploaded.

UserState Additional information attached by the user.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerPost Class

UploadManagerPost Members

UploadManagerSettings Contains parameters that specify the behavior of IUploadManager objects.

Object Model

Syntax

Visual Basic (Declaration)

Page 156: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

154

Public MustInherit Class UploadManagerSettings

C#

public abstract class UploadManagerSettings

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.UploadManagerSettings

C1.Silverlight.Uploader.UploadManagerSettingsPost

C1.Silverlight.Uploader.UploadManagerSettingsWebService

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettings Members

C1.Silverlight.Uploader Namespace

Overview Contains parameters that specify the behavior of IUploadManager objects.

Object Model

Syntax

Visual Basic (Declaration)

Public MustInherit Class UploadManagerSettings

C#

public abstract class UploadManagerSettings

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.UploadManagerSettings

C1.Silverlight.Uploader.UploadManagerSettingsPost

C1.Silverlight.Uploader.UploadManagerSettingsWebService

Requirements

Page 157: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

155

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettings Members

C1.Silverlight.Uploader Namespace

Members Properties

The following tables list the members exposed by UploadManagerSettings.

Public Properties

Name Description

Address Gets or sets the address of the service that will receive the upload

Top

See Also

Reference

UploadManagerSettings Class

C1.Silverlight.Uploader Namespace

Properties >

Name Description

Address Gets or sets the address of the service that will receive the upload

Top

See Also

Reference

UploadManagerSettings Class

C1.Silverlight.Uploader Namespace

Address Property Gets or sets the address of the service that will receive the upload

Syntax

Page 158: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

156

Visual Basic (Declaration)

Public Property Address As System.Uri

C#

public System.Uri Address {get; set;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettings Class

UploadManagerSettings Members

UploadManagerSettingsPost Contains parameters that specify the behavior of UploadManagerPost objects.

Object Model

Syntax

Visual Basic (Declaration)

Public Class UploadManagerSettingsPost

Inherits UploadManagerSettings

C#

public class UploadManagerSettingsPost : UploadManagerSettings

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.UploadManagerSettings

C1.Silverlight.Uploader.UploadManagerSettingsPost

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

Page 159: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

157

See Also

Reference

UploadManagerSettingsPost Members

C1.Silverlight.Uploader Namespace

Overview Contains parameters that specify the behavior of UploadManagerPost objects.

Object Model

Syntax

Visual Basic (Declaration)

Public Class UploadManagerSettingsPost

Inherits UploadManagerSettings

C#

public class UploadManagerSettingsPost : UploadManagerSettings

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.UploadManagerSettings

C1.Silverlight.Uploader.UploadManagerSettingsPost

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettingsPost Members

C1.Silverlight.Uploader Namespace

Members Properties

The following tables list the members exposed by UploadManagerSettingsPost.

Public Constructors

Page 160: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

158

Name Description

UploadManagerSettingsPost Constructor Overloaded.

Top

Public Properties

Name Description

Address Gets or sets the address of the service that will receive the upload

(Inherited from C1.Silverlight.Uploader.UploadManagerSettings)

Boundary Gets or sets the boundary used to create the multipart post.

TransferEncoding Gets or sets the encoding used to transfer the parts to the server.

Top

See Also

Reference

UploadManagerSettingsPost Class

C1.Silverlight.Uploader Namespace

UploadManagerSettingsPost Constructor

Overload List

Overload Description

UploadManagerSettingsPost Constructor(Uri) Initializes a new instance of a

UploadManagerSettingsPost.

UploadManagerSettingsPost Constructor() Initializes a new instance of a

UploadManagerSettingsPost.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

Page 161: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

159

UploadManagerSettingsPost Class

UploadManagerSettingsPost Members

UploadManagerSettingsPost Constructor(Uri) Address of the service that will receive the upload

Initializes a new instance of a UploadManagerSettingsPost.

Syntax

Visual Basic (Declaration)

Public Function New( _

ByVal address As System.Uri _

)

C#

public UploadManagerSettingsPost(

System.Uri address

)

Parameters

address

Address of the service that will receive the upload

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows

Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported

with SP1 or later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettingsPost Class

UploadManagerSettingsPost Members

Overload List

UploadManagerSettingsPost Constructor() Initializes a new instance of a UploadManagerSettingsPost.

Syntax

Visual Basic (Declaration)

Public Function New()

Page 162: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

160

C#

public UploadManagerSettingsPost()

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettingsPost Class

UploadManagerSettingsPost Members

Overload List

Properties >

Name Description

Address

Gets or sets the address of the service that will receive the upload

(Inherited from C1.Silverlight.Uploader.UploadManagerSettings)

Boundary Gets or sets the boundary used to create the multipart post.

TransferEncoding Gets or sets the encoding used to transfer the parts to the server.

Top

See Also

Reference

UploadManagerSettingsPost Class

C1.Silverlight.Uploader Namespace

Boundary Property Gets or sets the boundary used to create the multipart post.

Syntax

Visual Basic (Declaration)

Public Property Boundary As System.String

C#

public System.string Boundary {get; set;}

Page 163: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

161

Remarks

If no boundary is specified the system will generate one randomly (Recommended).

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettingsPost Class

UploadManagerSettingsPost Members

TransferEncoding Property Gets or sets the encoding used to transfer the parts to the server.

Syntax

Visual Basic (Declaration)

Public Property TransferEncoding As MultipartPostEncoding

C#

public MultipartPostEncoding TransferEncoding {get; set;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettingsPost Class

UploadManagerSettingsPost Members

UploadManagerSettingsWebService Contains parameters that specify the behavior of UploadManagerWebService objects.

Object Model

Syntax

Page 164: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

162

Visual Basic (Declaration)

Public Class UploadManagerSettingsWebService

Inherits UploadManagerSettings

C#

public class UploadManagerSettingsWebService : UploadManagerSettings

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.UploadManagerSettings

C1.Silverlight.Uploader.UploadManagerSettingsWebService

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettingsWebService Members

C1.Silverlight.Uploader Namespace

Overview Contains parameters that specify the behavior of UploadManagerWebService objects.

Object Model

Syntax

Visual Basic (Declaration)

Public Class UploadManagerSettingsWebService

Inherits UploadManagerSettings

C#

public class UploadManagerSettingsWebService : UploadManagerSettings

Inheritance Hierarchy

Page 165: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

163

System.Object

C1.Silverlight.Uploader.UploadManagerSettings

C1.Silverlight.Uploader.UploadManagerSettingsWebService

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettingsWebService Members

C1.Silverlight.Uploader Namespace

Members Properties

The following tables list the members exposed by UploadManagerSettingsWebService.

Public Constructors

Name Description

UploadManagerSettingsWebService Constructor Overloaded.

Top

Public Properties

Name Description

Address Gets or sets the address of the service that will receive the upload

(Inherited from C1.Silverlight.Uploader.UploadManagerSettings)

MethodManyFiles Gets or sets the name of the WebMethod which receives the upload.

MethodOneFile Gets or sets the name of the WebMethod which receives the upload.

Namespace Gets or sets the namespace of the WebService which receive the

upload.

ParamFileData Gets or sets the name of the parameter that receives the data of the

part.

Page 166: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

164

ParamFileName Gets or sets the name of the parameter that receives the name of the

part.

ParamFiles Gets or sets the name of the parameter that receives the list of files.

ParamParameters Gets or sets the name of the parameter that receives optional

parameters specified in the Uploader component.

ParamPartCount Gets or sets the name of the parameter that receives the number of

parts.

ParamPartNumber Gets or sets the name of the parameter that receives the index of the

part.

Top

See Also

Reference

UploadManagerSettingsWebService Class

C1.Silverlight.Uploader Namespace

UploadManagerSettingsWebService Constructor

Overload List

Overload Description

UploadManagerSettingsWebService Constructor(Uri) Initializes a new instance of a

UploadManagerSettingsWebService.

UploadManagerSettingsWebService Constructor() Initializes a new instance of a

UploadManagerSettingsWebService.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettingsWebService Class

UploadManagerSettingsWebService Members

Page 167: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

165

UploadManagerSettingsWebService Constructor(Uri) System.Uri of the service that will receive the upload requests.

Initializes a new instance of a UploadManagerSettingsWebService.

Syntax

Visual Basic (Declaration)

Public Function New( _

ByVal address As System.Uri _

)

C#

public UploadManagerSettingsWebService(

System.Uri address

)

Parameters

address

System.Uri of the service that will receive the upload requests.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows

Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported

with SP1 or later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettingsWebService Class

UploadManagerSettingsWebService Members

Overload List

UploadManagerSettingsWebService Constructor() Initializes a new instance of a UploadManagerSettingsWebService.

Syntax

Visual Basic (Declaration)

Public Function New()

C#

public UploadManagerSettingsWebService()

Page 168: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

166

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettingsWebService Class

UploadManagerSettingsWebService Members

Overload List

Properties >

Name Description

Address

Gets or sets the address of the service that will receive the upload

(Inherited from C1.Silverlight.Uploader.UploadManagerSettings)

MethodManyFiles Gets or sets the name of the WebMethod which receives the upload.

MethodOneFile Gets or sets the name of the WebMethod which receives the upload.

Namespace

Gets or sets the namespace of the WebService which receive the

upload.

ParamFileData

Gets or sets the name of the parameter that receives the data of the

part.

ParamFileName

Gets or sets the name of the parameter that receives the name of the

part.

ParamFiles Gets or sets the name of the parameter that receives the list of files.

ParamParameters

Gets or sets the name of the parameter that receives optional

parameters specified in the Uploader component.

ParamPartCount

Gets or sets the name of the parameter that receives the number of

parts.

ParamPartNumber

Gets or sets the name of the parameter that receives the index of the

part.

Top

See Also

Reference

Page 169: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

167

UploadManagerSettingsWebService Class

C1.Silverlight.Uploader Namespace

MethodManyFiles Property Gets or sets the name of the WebMethod which receives the upload.

Syntax

Visual Basic (Declaration)

Public Property MethodManyFiles As System.String

C#

public System.string MethodManyFiles {get; set;}

Remarks

Default value is UploadFiles.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettingsWebService Class

UploadManagerSettingsWebService Members

MethodOneFile Property Gets or sets the name of the WebMethod which receives the upload.

Syntax

Visual Basic (Declaration)

Public Property MethodOneFile As System.String

C#

public System.string MethodOneFile {get; set;}

Remarks

Default value is UploadFile.

Requirements

Page 170: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

168

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettingsWebService Class

UploadManagerSettingsWebService Members

Namespace Property Gets or sets the namespace of the WebService which receive the upload.

Syntax

Visual Basic (Declaration)

Public Property Namespace As System.String

C#

public System.string Namespace {get; set;}

Remarks

Default value is http://tempuri.org/.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettingsWebService Class

UploadManagerSettingsWebService Members

ParamFileData Property Gets or sets the name of the parameter that receives the data of the part.

Syntax

Visual Basic (Declaration)

Public Property ParamFileData As System.String

C#

Page 171: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

169

public System.string ParamFileData {get; set;}

Remarks

The data is received as a string formatted in base64.Default value is fileData.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettingsWebService Class

UploadManagerSettingsWebService Members

ParamFileName Property Gets or sets the name of the parameter that receives the name of the part.

Syntax

Visual Basic (Declaration)

Public Property ParamFileName As System.String

C#

public System.string ParamFileName {get; set;}

Remarks

Default value is filename.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettingsWebService Class

UploadManagerSettingsWebService Members

ParamFiles Property Gets or sets the name of the parameter that receives the list of files.

Page 172: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

170

Syntax

Visual Basic (Declaration)

Public Property ParamFiles As System.String

C#

public System.string ParamFiles {get; set;}

Remarks

Default value is files.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettingsWebService Class

UploadManagerSettingsWebService Members

ParamParameters Property Gets or sets the name of the parameter that receives optional parameters specified in the

Uploader component.

Syntax

Visual Basic (Declaration)

Public Property ParamParameters As System.String

C#

public System.string ParamParameters {get; set;}

Remarks

Default value is parameters.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

Page 173: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

171

See Also

Reference

UploadManagerSettingsWebService Class

UploadManagerSettingsWebService Members

ParamPartCount Property Gets or sets the name of the parameter that receives the number of parts.

Syntax

Visual Basic (Declaration)

Public Property ParamPartCount As System.String

C#

public System.string ParamPartCount {get; set;}

Remarks

Default value is partCount.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettingsWebService Class

UploadManagerSettingsWebService Members

ParamPartNumber Property Gets or sets the name of the parameter that receives the index of the part.

Syntax

Visual Basic (Declaration)

Public Property ParamPartNumber As System.String

C#

public System.string ParamPartNumber {get; set;}

Remarks

Page 174: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

172

Default value is partNumber.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerSettingsWebService Class

UploadManagerSettingsWebService Members

UploadManagerWebService Class that packages files into Web Service requests.

Object Model

Syntax

Visual Basic (Declaration)

Public Class UploadManagerWebService

Implements IUploadManager

C#

public class UploadManagerWebService : IUploadManager

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.UploadManagerWebService

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerWebService Members

C1.Silverlight.Uploader Namespace

Page 175: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

173

Overview Class that packages files into Web Service requests.

Object Model

Syntax

Visual Basic (Declaration)

Public Class UploadManagerWebService

Implements IUploadManager

C#

public class UploadManagerWebService : IUploadManager

Inheritance Hierarchy

System.Object

C1.Silverlight.Uploader.UploadManagerWebService

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerWebService Members

C1.Silverlight.Uploader Namespace

Members Methods Events

The following tables list the members exposed by UploadManagerWebService.

Public Constructors

Name Description

UploadManagerWebService Constructor

Top

Public Methods

Page 176: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

174

Name Description

BeginUpload Begins the upload of one part.

Cancel Aborts the execution of the upload.

Top

Public Events

Name Description

UploadCompleted It is raised when the upload has been completed.

UploadProgressChanged It is raised when the progress of the upload has changed.

Top

See Also

Reference

UploadManagerWebService Class

C1.Silverlight.Uploader Namespace

UploadManagerWebService Constructor

Syntax

Visual Basic (Declaration)

Public Function New()

C#

public UploadManagerWebService()

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerWebService Class

UploadManagerWebService Members

Page 177: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

175

Methods >

Name Description

BeginUpload Begins the upload of one part.

Cancel Aborts the execution of the upload.

Top

See Also

Reference

UploadManagerWebService Class

C1.Silverlight.Uploader Namespace

BeginUpload Method Settings used to upload the part.

Package of file parts to be uploaded.

Headers that will be sent within the upload.

Parameter that will be sent to the server together with the part.

Begins the upload of one part.

Syntax

Visual Basic (Declaration)

Public Function BeginUpload( _

ByVal settings As UploadManagerSettings, _

ByVal package As UploadFilePartPackage, _

ByVal headers As System.Collections.Generic.Dictionary(Of

HttpRequestHeader,String), _

ByVal parameters As System.Collections.Generic.Dictionary(Of

String,String) _

) As System.Boolean

C#

public System.bool BeginUpload(

UploadManagerSettings settings,

UploadFilePartPackage package,

System.Collections.Generic.Dictionary<HttpRequestHeader,string> headers,

System.Collections.Generic.Dictionary<string,string> parameters

)

Page 178: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

176

Parameters

settings

Settings used to upload the part.

package

Package of file parts to be uploaded.

headers

Headers that will be sent within the upload.

parameters

Parameter that will be sent to the server together with the part.

Return Value

Returns True, if the upload has been started correctly.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP

SP3, Windows Server 2008 (Server Core not supported), Windows Server

2008 R2 (Server Core supported with SP1 or later), Windows Server 2003

SP2

See Also

Reference

UploadManagerWebService Class

UploadManagerWebService Members

Cancel Method Aborts the execution of the upload.

Syntax

Visual Basic (Declaration)

Public Sub Cancel()

C#

public void Cancel()

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

Page 179: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

177

See Also

Reference

UploadManagerWebService Class

UploadManagerWebService Members

Events >

Name Description

UploadCompleted It is raised when the upload has been completed.

UploadProgressChanged It is raised when the progress of the upload has changed.

Top

See Also

Reference

UploadManagerWebService Class

C1.Silverlight.Uploader Namespace

UploadCompleted Event It is raised when the upload has been completed.

Syntax

Visual Basic (Declaration)

Public Event UploadCompleted As System.EventHandler(Of

UploadCompletedEventArgs)

C#

public event System.EventHandler<UploadCompletedEventArgs> UploadCompleted

Event Data

The event handler receives an argument of type UploadCompletedEventArgs containing data

related to this event. The following UploadCompletedEventArgs properties provide

information specific to this event.

Property Description

Cancelled (Inherited from System.ComponentModel.AsyncCompletedEventArgs)

Error (Inherited from System.ComponentModel.AsyncCompletedEventArgs)

Page 180: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

178

Files Array of names of the files uploaded

Response Response returned by the server in the message body.

Success True if all the files were uploaded successfully.

UserState (Inherited from System.ComponentModel.AsyncCompletedEventArgs)

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerWebService Class

UploadManagerWebService Members

UploadProgressChanged Event It is raised when the progress of the upload has changed.

Syntax

Visual Basic (Declaration)

Public Event UploadProgressChanged As System.EventHandler(Of

UploadProgressChangedEventArgs)

C#

public event System.EventHandler<UploadProgressChangedEventArgs>

UploadProgressChanged

Event Data

The event handler receives an argument of type UploadProgressChangedEventArgs containing

data related to this event. The following UploadProgressChangedEventArgs properties

provide information specific to this event.

Property Description

BytesUploaded Amount of bytes that were uploaded.

ProgressPercentage Percentage of bytes that were uploaded.

Page 181: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

179

TotalBytesToUpload Amount of bytes that must be uploaded.

UserState Additional information attached by the user.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadManagerWebService Class

UploadManagerWebService Members

UploadProgressChangedEventArgs Contains data about progress changed event of the upload file.

Object Model

Syntax

Visual Basic (Declaration)

Public Class UploadProgressChangedEventArgs

Inherits System.EventArgs

C#

public class UploadProgressChangedEventArgs : System.EventArgs

Inheritance Hierarchy

System.Object

System.EventArgs

C1.Silverlight.Uploader.UploadProgressChangedEventArgs

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Page 182: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

180

Reference

UploadProgressChangedEventArgs Members

C1.Silverlight.Uploader Namespace

Overview Contains data about progress changed event of the upload file.

Object Model

Syntax

Visual Basic (Declaration)

Public Class UploadProgressChangedEventArgs

Inherits System.EventArgs

C#

public class UploadProgressChangedEventArgs : System.EventArgs

Inheritance Hierarchy

System.Object

System.EventArgs

C1.Silverlight.Uploader.UploadProgressChangedEventArgs

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadProgressChangedEventArgs Members

C1.Silverlight.Uploader Namespace

Members Properties

The following tables list the members exposed by UploadProgressChangedEventArgs.

Public Constructors

Name Description

Page 183: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

181

UploadProgressChangedEventArgs Constructor Initializes a new instance of a

UploadProgressChangedEventArgs.

Top

Public Properties

Name Description

BytesUploaded Amount of bytes that were uploaded.

ProgressPercentage Percentage of bytes that were uploaded.

TotalBytesToUpload Amount of bytes that must be uploaded.

UserState Additional information attached by the user.

Top

See Also

Reference

UploadProgressChangedEventArgs Class

C1.Silverlight.Uploader Namespace

UploadProgressChangedEventArgs Constructor Amount of bytes that were uploaded

Amount of bytes that must be uploaded

Additional information attached by the user

Initializes a new instance of a UploadProgressChangedEventArgs.

Syntax

Visual Basic (Declaration)

Public Function New( _

ByVal bytesUploaded As System.Long, _

ByVal totalBytesToUpload As System.Long, _

ByVal userState As System.Object _

)

C#

public UploadProgressChangedEventArgs(

Page 184: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

182

System.long bytesUploaded,

System.long totalBytesToUpload,

System.object userState

)

Parameters

bytesUploaded

Amount of bytes that were uploaded

totalBytesToUpload

Amount of bytes that must be uploaded

userState

Additional information attached by the user

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3,

Windows Server 2008 (Server Core not supported), Windows Server 2008 R2

(Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

UploadProgressChangedEventArgs Class

UploadProgressChangedEventArgs Members

Properties >

Name Description

BytesUploaded Amount of bytes that were uploaded.

ProgressPercentage Percentage of bytes that were uploaded.

TotalBytesToUpload Amount of bytes that must be uploaded.

UserState Additional information attached by the user.

Top

See Also

Reference

UploadProgressChangedEventArgs Class

C1.Silverlight.Uploader Namespace

Page 185: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

183

BytesUploaded Property Amount of bytes that were uploaded.

Syntax

Visual Basic (Declaration)

Public ReadOnly Property BytesUploaded As System.Long

C#

public System.long BytesUploaded {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadProgressChangedEventArgs Class

UploadProgressChangedEventArgs Members

ProgressPercentage Property Percentage of bytes that were uploaded.

Syntax

Visual Basic (Declaration)

Public ReadOnly Property ProgressPercentage As System.Integer

C#

public System.int ProgressPercentage {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadProgressChangedEventArgs Class

UploadProgressChangedEventArgs Members

Page 186: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

184

TotalBytesToUpload Property Amount of bytes that must be uploaded.

Syntax

Visual Basic (Declaration)

Public ReadOnly Property TotalBytesToUpload As System.Long

C#

public System.long TotalBytesToUpload {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadProgressChangedEventArgs Class

UploadProgressChangedEventArgs Members

UserState Property Additional information attached by the user.

Syntax

Visual Basic (Declaration)

Public ReadOnly Property UserState As System.Object

C#

public System.object UserState {get;}

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

UploadProgressChangedEventArgs Class

UploadProgressChangedEventArgs Members

Page 187: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

185

Enumerations

FilesPerRequest Specifies how files are mapped into server requests.

Syntax

Visual Basic (Declaration)

Public Enum FilesPerRequest

Inherits System.Enum

C#

public enum FilesPerRequest : System.Enum

Members

Member Description

AllFilesInOneRequest All files will be uploaded in a single request. This is more

efficient when uploading many small files.

OneFilePerRequest Each request contains one file. This is the default setting.

SplitFilesIntoMultipleRequests Each file will be split into multiple requests. Indicated when

uploading very large files.

Inheritance Hierarchy

System.Object

System.ValueType

System.Enum

C1.Silverlight.Uploader.FilesPerRequest

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1.Silverlight.Uploader Namespace

Page 188: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

186

MultipartPostEncoding Specifies the encoding of the data that will be sent in the post message.

Syntax

Visual Basic (Declaration)

Public Enum MultipartPostEncoding

Inherits System.Enum

C#

public enum MultipartPostEncoding : System.Enum

Members

Member Description

Base64 Data encoded in Base64 format

Binary Data encoded in binary format.

Inheritance Hierarchy

System.Object

System.ValueType

System.Enum

C1.Silverlight.Uploader.MultipartPostEncoding

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

C1.Silverlight.Uploader Namespace

Interfaces

IUploadManager Interface implemented by classes that package files into server requests.

Object Model

Page 189: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

187

Syntax

Visual Basic (Declaration)

Public Interface IUploadManager

C#

public interface IUploadManager

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

IUploadManager Members

C1.Silverlight.Uploader Namespace

Overview Interface implemented by classes that package files into server requests.

Object Model

Syntax

Visual Basic (Declaration)

Public Interface IUploadManager

C#

public interface IUploadManager

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

Page 190: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

188

IUploadManager Members

C1.Silverlight.Uploader Namespace

Members Methods Events

The following tables list the members exposed by IUploadManager.

Public Methods

Name Description

BeginUpload Begins the upload of one UploadFilePartPackage

Cancel Cancels the current upload process.

Top

Public Events

Name Description

UploadCompleted Event that fires when the upload process has been completed.

UploadProgressChanged Event that fires when the upload process makes progress.

Top

See Also

Reference

IUploadManager Interface

C1.Silverlight.Uploader Namespace

Methods >

Name Description

BeginUpload Begins the upload of one UploadFilePartPackage

Cancel Cancels the current upload process.

Top

See Also

Reference

Page 191: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

189

IUploadManager Interface

C1.Silverlight.Uploader Namespace

BeginUpload Method UploadManagerSettings that specify how to perform the upload.

UploadFilePartPackage that contains file parts to be uploaded.

Headers that will be sent with the upload requests.

Parameters that will be sent to the server with the upload requests.

Begins the upload of one UploadFilePartPackage

Syntax

Visual Basic (Declaration)

Function BeginUpload( _

ByVal settings As UploadManagerSettings, _

ByVal package As UploadFilePartPackage, _

ByVal headers As System.Collections.Generic.Dictionary(Of

HttpRequestHeader,String), _

ByVal parameters As System.Collections.Generic.Dictionary(Of

String,String) _

) As System.Boolean

C#

System.bool BeginUpload(

UploadManagerSettings settings,

UploadFilePartPackage package,

System.Collections.Generic.Dictionary<HttpRequestHeader,string> headers,

System.Collections.Generic.Dictionary<string,string> parameters

)

Parameters

settings

UploadManagerSettings that specify how to perform the upload.

package

UploadFilePartPackage that contains file parts to be uploaded.

headers

Headers that will be sent with the upload requests.

parameters

Parameters that will be sent to the server with the upload requests.

Page 192: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

190

Return Value

Returns true if the upload process started successfully.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP

SP3, Windows Server 2008 (Server Core not supported), Windows Server

2008 R2 (Server Core supported with SP1 or later), Windows Server 2003

SP2

See Also

Reference

IUploadManager Interface

IUploadManager Members

Cancel Method Cancels the current upload process.

Syntax

Visual Basic (Declaration)

Sub Cancel()

C#

void Cancel()

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

IUploadManager Interface

IUploadManager Members

Events %%scrap%%

" -->

For a list of all members of this type, see IUploadManager members.

Public Events

Page 193: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

191

Name Description

UploadCompleted Event that fires when the upload process has been completed.

UploadProgressChanged Event that fires when the upload process makes progress.

Top

See Also

Reference

IUploadManager Interface

C1.Silverlight.Uploader Namespace

UploadCompleted Event Event that fires when the upload process has been completed.

Syntax

Visual Basic (Declaration)

Event UploadCompleted As System.EventHandler(Of UploadCompletedEventArgs)

C#

event System.EventHandler<UploadCompletedEventArgs> UploadCompleted

Event Data

The event handler receives an argument of type UploadCompletedEventArgs containing data

related to this event. The following UploadCompletedEventArgs properties provide

information specific to this event.

Property Description

Cancelled (Inherited from System.ComponentModel.AsyncCompletedEventArgs)

Error (Inherited from System.ComponentModel.AsyncCompletedEventArgs)

Files Array of names of the files uploaded

Response Response returned by the server in the message body.

Success True if all the files were uploaded successfully.

UserState (Inherited from System.ComponentModel.AsyncCompletedEventArgs)

Page 194: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

192

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

See Also

Reference

IUploadManager Interface

IUploadManager Members

UploadProgressChanged Event Event that fires when the upload process makes progress.

Syntax

Visual Basic (Declaration)

Event UploadProgressChanged As System.EventHandler(Of

UploadProgressChangedEventArgs)

C#

event System.EventHandler<UploadProgressChangedEventArgs>

UploadProgressChanged

Event Data

The event handler receives an argument of type UploadProgressChangedEventArgs containing

data related to this event. The following UploadProgressChangedEventArgs properties

provide information specific to this event.

Property Description

BytesUploaded Amount of bytes that were uploaded.

ProgressPercentage Percentage of bytes that were uploaded.

TotalBytesToUpload Amount of bytes that must be uploaded.

UserState Additional information attached by the user.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server

2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or

later), Windows Server 2003 SP2

Page 195: ComponentOne Uploader for Silverlightprerelease.componentone.com/help/Silverlight/Silverlight... · 2015-07-17 · Uploader for Silverlight Quick Start > Step 1 of 4: Creating a Silverlight

193

See Also

Reference

IUploadManager Interface

IUploadManager Members

Delegates

C1UploaderPost.MIMETypeRequestedEventHandler Represents the method that will handle the C1UploaderPost.MIMETypeRequested event.

Syntax

Visual Basic (Declaration)

Public Delegate Function C1UploaderPost.MIMETypeRequestedEventHandler( _

ByVal sender As System.Object, _

ByVal e As MIMETypeRequestedEventArgs _

) As System.String

C#

public delegate System.string C1UploaderPost.MIMETypeRequestedEventHandler(

System.object sender,

MIMETypeRequestedEventArgs e

)

Parameters

sender

e

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3,

Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server

Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

C1UploaderPost.MIMETypeRequestedEventHandler Members

C1.Silverlight.Uploader Namespace