Changing the name of the file with session variables or Request.QueryString

5 posts, 0 answers
  1. Geraldo Santos
    Geraldo Santos avatar
    3 posts
    Member since:
    Feb 2010

    Posted 10 Dec 2013 Link to this post

    I need to change the file name based on a parameter passed by url
    but the class does not allow me to access the request.
    how can I get access to session variables or passed in the url within the parameters Telerik.Web.UI.CloudUploadHandler class?

    see my code below.


    Imports System
    Imports System.Web
    Imports System.Web.Services

    Public Class vendedores_img : Inherits Telerik.Web.UI.CloudUploadHandler

        Public Overrides Sub SetKeyName(sender As Object, e As Telerik.Web.UI.CloudUpload.SetKeyNameEventArgs)

            e.KeyName = "vendedores-img-pg/" & e.OriginalFileName

        End Sub
        Public Overloads Sub ProcessRequest(context As System.Web.HttpContext) ' *** Not that performing this procedure ***
            Dim vID As String = context.Request.QueryString("ContaID")
            e.KeyName = vID
    ' *** Not that performing this procedure ***
        End Sub

    End Class
  2. Peter Filipov
    Admin
    Peter Filipov avatar
    1028 posts

    Posted 12 Dec 2013 Link to this post

    Hello Geraldo,

    Please review my answer in the following post. In order to avoid duplication of the thread, please continue the conversation in one of them.

    Regards,
    Peter Filipov
    Telerik
     
    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 the blog feed now.
     
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Geraldo Santos
    Geraldo Santos avatar
    3 posts
    Member since:
    Feb 2010

    Posted 12 Dec 2013 Link to this post

    Perfect resolved.

    Thank you very much for attention.

    Greetings.
  5. Marcus
    Marcus avatar
    2 posts
    Member since:
    Sep 2014

    Posted 20 Feb 2015 in reply to Peter Filipov Link to this post

    The link what you post are brocked: 
    http://www.telerik.com/forums/www.telerik.com/community/forums/aspnet-ajax/cloud-upload/change-name-of-file-before-uploading-to-azure.aspx

    Than, next post says ithis solve the problem I need it. 

    Tanks     
  6. Peter Filipov
    Admin
    Peter Filipov avatar
    1028 posts

    Posted 23 Feb 2015 Link to this post

    Hello Geraldo,

    You could the link here:
    http://www.telerik.com/forums/change-name-of-file-before-uploading-to-azure

    Regards,
    Peter Filipov
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017