This is a migrated thread and some comments may be shown as answers.

Setting ImageURL property for non-relative paths

3 Answers 219 Views
ImageEditor
This is a migrated thread and some comments may be shown as answers.
Dan
Top achievements
Rank 1
Dan asked on 18 Oct 2011, 09:25 PM
In my application I need to load, edit, and save edited images that are not part of the web site running the page that contains the RadImageEditor. Note that the images are on the same web SERVER as the page running RadImageEditor, but they are on a different web SITE.

It appears that the ImageURL property only accepts a path that is relative to the web site running the applicaition/page
 (at least by default).  Otherwise, an error is thrown.  In my case, the error looks something like this:

Exception type: System.Web.HttpException
Message: 'http://pictures.mywebsite.com/001/graphics/DSC00752.JPG' is not a valid virtual path.
Stack trace:    at System.Web.Util.UrlPath.CheckValidVirtualPath(String path)
   at System.Web.Util.UrlPath.Combine(String appPath, String basepath, String relative)
   at System.Web.VirtualPath.Combine(VirtualPath relativePath)
   at System.Web.UI.Control.ResolvePhysicalOrVirtualPath(String path, VirtualPath& virtualPath, String& physicalPath)
   at System.Web.UI.Control.MapPathSecure(String virtualPath)
   at Telerik.Web.UI.RadImageEditor.GetCurrentEditableImage()
   at Telerik.Web.UI.RadImageEditor.ApplyClientOperations()
   at Telerik.Web.UI.RadImageEditor.ControlPreRender()
   at Telerik.Web.UI.RadWebControl.OnPreRender(EventArgs e)
   at System.Web.UI.Control.PreRenderRecursiveInternal()
   at System.Web.UI.Control.PreRenderRecursiveInternal()
   at System.Web.UI.Control.PreRenderRecursiveInternal()
   at System.Web.UI.Control.PreRenderRecursiveInternal()
   at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

How can I access (load/edit/save) images in RadImageEditor that are outside the relative path?

Thanks.

3 Answers, 1 is accepted

Sort by
0
Dobromir
Telerik team
answered on 21 Oct 2011, 11:35 AM
Hi Dan,

At present, RadImageEditor cannot work with physical paths for images.

However, in the upcoming release of RadControls for ASP.NET AJAX will will introduce support for custom content providers (using the same approach as RadFileExplorer) for RadImageEditor and this will allow the control to work with various storage types.

In addition, we are targeting the release of RadControls for ASP.NET AJAX Q3 2011 to be in the middle of November.

Greetings,
Dobromir
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now
0
Zi
Top achievements
Rank 1
answered on 13 Nov 2012, 07:11 PM
Hi, I am also meeting the same issue, is it fixed? How could I do it? Thanks.
0
Vessy
Telerik team
answered on 14 Nov 2012, 09:13 AM
Hi Dan,

The ImageEditor now supports Custom content providers and you could find more information on how to implement such in the following help article: Using a Custom Image Provider.

Regards,
Vesi
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
ImageEditor
Asked by
Dan
Top achievements
Rank 1
Answers by
Dobromir
Telerik team
Zi
Top achievements
Rank 1
Vessy
Telerik team
Share this question
or