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

How to open Upload Window client side?

1 Answer 85 Views
FileExplorer
This is a migrated thread and some comments may be shown as answers.
Steve White
Top achievements
Rank 1
Steve White asked on 15 Jan 2010, 10:41 AM
I have added a new Grid ContextMenuItem and added a handler for the click event. I want to open the Upload Window on this event but don't know how to do it. This functionality is to allow for document versioning and I'll do all of the checks for versioning serverside.

Here's the handler:

    function OnClientContextMenuItemClicked(sender, args) { 
        var buttonValue = args.get_item().get_value(); 
        if (buttonValue == "Checkin") { 
            var oExplorer = $find("<%= DocumentExplorer.ClientID %>"); 
            var oAjax = $find("RadAjaxManager"); 
            // I want to open the upload window here 
        } 
    } 
 

Thanks,
Steve


1 Answer, 1 is accepted

Sort by
0
Steve White
Top achievements
Rank 1
answered on 15 Jan 2010, 10:54 AM
I got it working by forcing the click event on the Upload toolbar button:

            var oExplorer = $find("<%= DocumentExplorer.ClientID %>"); 
            var toolbar = oExplorer.get_toolbar(); 
            var uploadButton = toolbar.findItemByValue("Upload"); 
            uploadButton.click(); 
 

Tags
FileExplorer
Asked by
Steve White
Top achievements
Rank 1
Answers by
Steve White
Top achievements
Rank 1
Share this question
or