Code behind

Last post 12-14-2009, 10:21 PM by cutechat. 1 replies.
Sort Posts: Previous Next
  •  12-14-2009, 7:05 PM 57755

    Code behind

    Can the code for using the uploader control be kept in the code behind page, or does it need to be part of the HTML page?  If yes, how do I reference the uploader arguments?
     
    Joe
  •  12-14-2009, 10:21 PM 57756 in reply to 57755

    Re: Code behind

    Joe,
     
    You can add the uploader into your control at each page life cycle ,
     
     
    Uploader up;
    protected override void OnInit(EventArgs args)
    {
        base.OnInit(args);
        up=new Uploader();
        up.FileUploaded+=new UploaderEventHandler(up_FileUploaded);
        mycontrolholder.Controls.Add(up);
    }
    private void up_FileUploaded(object sender, UploaderEventArgs args)
    {
    }
     
     
    Regards,
    Terry
     
View as RSS news feed in XML