For those of us using WCF RIA Services as the storage interface for our Silverlight applications, what is the best way to leverage the RadUpload? I would like to use it to have the application user be able to upload and display a picture in the application.
It seems that there is no direct mechanism to use in conjunction with WCF RIA Services. Is there some sort of good design pattern or example that you can demonstrate? Do we have to create a generic service seperate of our WCF RIA services just to upload\download the images?
It seems that there is no direct mechanism to use in conjunction with WCF RIA Services. Is there some sort of good design pattern or example that you can demonstrate? Do we have to create a generic service seperate of our WCF RIA services just to upload\download the images?
5 Answers, 1 is accepted
0
Hello Jason,
Can you elaborate a little bit more how you want to use the Upload with the WCF service? Do you want to save an image into the database and then to display it from the database using a WCF service, or you mean something else?
Kind regards,
Valentin.Stoychev
the Telerik team
Can you elaborate a little bit more how you want to use the Upload with the WCF service? Do you want to save an image into the database and then to display it from the database using a WCF service, or you mean something else?
Kind regards,
Valentin.Stoychev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Karanjit Siyan
Top achievements
Rank 1
answered on 03 Aug 2010, 01:19 PM
I have a similar requirement. Once file is uploaded to the ASP.NET server folder, I want to be able to stored the data in the uploaded file to a database. Assume that I have a stored proc interface via the RIA services that I can call. Please post some sample code, and write comments for the interface to the database since that part has to be generic.
0
Hi Karanjit Siyan,
The RadUploadHandler is the default server endpoint for the upload and you can extend it by inheriting it.
Using the RadUpload with RiaServices is possible. For example if you store images, you can keep just the image path in your business object (and DB). Retrieving the image can happen as an absolute url from your server or via a handler.
What you need is to updated your DB after the upload has completed.
This KB article can get you started on processing files on upload:
http://www.telerik.com/support/kb/silverlight/upload/process-files-on-server.aspx
All the best,
Miroslav
the Telerik team
The RadUploadHandler is the default server endpoint for the upload and you can extend it by inheriting it.
Using the RadUpload with RiaServices is possible. For example if you store images, you can keep just the image path in your business object (and DB). Retrieving the image can happen as an absolute url from your server or via a handler.
What you need is to updated your DB after the upload has completed.
This KB article can get you started on processing files on upload:
http://www.telerik.com/support/kb/silverlight/upload/process-files-on-server.aspx
All the best,
Miroslav
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Jason Nguyen
Top achievements
Rank 1
answered on 23 Aug 2010, 05:33 PM
Do you still support only Http Handlers (ashx generic handler in MSVS)? I haven't found anything in the release notes stating otherwise.
In my scenario we are using WCF Ria Services with Silverlight 4 and we have a WCF RIA Services Class Library. This class library stores all of the services, we did this so we could seperate them from the Website project. Is it possible for me to do the server side of the radUpload in this WCF Ria Services Class Library?
In my scenario we are using WCF Ria Services with Silverlight 4 and we have a WCF RIA Services Class Library. This class library stores all of the services, we did this so we could seperate them from the Website project. Is it possible for me to do the server side of the radUpload in this WCF Ria Services Class Library?
0
Hello Jason Nguyen,
Yes, we are using a HttpHandler.
The code behind for the upload handler can be kept in any separate class library. The handler's markup file though needs to be in the web project:
All the best,
Miroslav
the Telerik team
Yes, we are using a HttpHandler.
The code behind for the upload handler can be kept in any separate class library. The handler's markup file though needs to be in the web project:
<%@ WebHandler Language="C#" Class="SLApp1.Web.MyUploadHandler" %>
All the best,
Miroslav
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items