Presentation is loading. Please wait.

Presentation is loading. Please wait.

Saving Files to Database Sams ASP NET 4 Unleashed.

Similar presentations


Presentation on theme: "Saving Files to Database Sams ASP NET 4 Unleashed."— Presentation transcript:

1 Saving Files to Database Sams ASP NET 4 Unleashed

2 Small Files: FileUploadDatabase.aspx

3 FileUploadDatabase.aspx: Form

4 FileUploadDatabase.aspx: Data Control

5 FileUploadDatabase.aspx: Data Source

6 Database Table

7 Reading the Uploaded Files: FileHandler.ashx

8 Use a generic HTTP Handler file Connect with

9 Upload Large Files

10 Do extra work when uploading large files Use less memory Upload in more manageable chunks Configure: httpRuntime maxRequestLength and httpRuntime requestLengthDiskThreshold maxRequestLength = 4MB requestLengthDiskThreshold  buffer

11 10MB limit, buffer of 100KB in Web.config

12 FileUploadLarge.aspx

13 FileUploadLarge.aspx: AddFile

14 FileUploadLarge.aspx: StoreFile

15 FileUploadLarge.aspx: Form

16 FileUploadLarge.aspx: Repeater

17 FileUploadLarge.aspx: Data Source

18 FileHandlerLarge.ashx

19

20

21 Problem Set 6 Modify PS45 and add product upload.


Download ppt "Saving Files to Database Sams ASP NET 4 Unleashed."

Similar presentations


Ads by Google