Setting ImageURL property for non-relative paths

4 posts, 0 answers
  1. Dan
    Dan avatar
    3 posts
    Member since:
    Aug 2012

    Posted 18 Oct 2011 Link to this post

    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.
  2. Dobromir
    Admin
    Dobromir avatar
    1633 posts

    Posted 21 Oct 2011 Link to this post

    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
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Zi
    Zi avatar
    1 posts
    Member since:
    Sep 2012

    Posted 13 Nov 2012 Link to this post

    Hi, I am also meeting the same issue, is it fixed? How could I do it? Thanks.
  5. Vessy
    Admin
    Vessy avatar
    1380 posts

    Posted 14 Nov 2012 Link to this post

    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.
Back to Top