Quantcast
Channel: DevExpress Support Center (Examples)
Viewing all articles
Browse latest Browse all 7205

OBSOLETE - Image Upload in ASPxGridView

$
0
0

UPDATED:

Starting with version v2015 vol 1 (v15.1), this functionality is available out of the box. Simply set the GridViewDataBinaryImageColumn.PropertiesBinaryImage.EditingSettings.Enabled property to True to activate it. Please refer to the ASP.NET Data Grid - Binary Image Editor (Coming soon in v15.1) blog post and the Binary Image Column Editing demo for more information.

If you have version v15.1+ available, consider using the built-in functionality instead of the approach detailed below.

The ASPxUploadControl can be used within the ASPxGridView's Edit Form to upload image files to the grid's bound database. In the online sample, the grid's data is stored within the Session object and is obtained/modified by using the ObjectDataSource component.

The project version that employs a SqlDataSource component is also provided in a separate zip file within the example folder.

See also:
How to bind the ASPxBinaryImage to a field which contains image data stored as OLE object
OBSOLETE - Inserting a new row in ASPxGridView with the image preview enabled

Question Comments

Added By: zain ul arfeen at: 1/23/2014 12:09:12 AM    

It is a nice post... But i cannot understand where and how should i bee using the file.SaveAs to save the file at some place???

Added By: Mehul Harry (DevExpress) at: 1/23/2014 2:26:42 PM    

Zain, you can download this entire project and run it locally in your VS. To see the relevant source files online, just cclick the dropdown above the code which let's you select the files. If you still need help then please contact our support team here: http://www.devexpress.com/Support/Center/CreateIssue.aspx?issuetype=Question

Thanks.


Viewing all articles
Browse latest Browse all 7205

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>