FileUltimate is a complex control so it will not work in UpdatePanel. Yes it's possible to update root folders on the client side however the control state needs to be updated on the server too because client side never knows the actual physical locations for security purpose.
So it's pretty complex, I think you should better use a iframe solution or you should accept the whole page postback.
For reference, I tried to prepare you an example project with some workarounds but I hit some problems with ScriptManager it seems some default ASP.NET javascript is conflicting, in browser console "TypeError: a is null" error is logged. Do you see a similar error? Because this error will also cause the control to appear blank. (UPDATE: This turned out to be a bug which is now fixed with release 5.0.7.0)
Even I couldn't get it to work for now, here is the idea:
<asp:UpdatePanel runat="server">
<ContentTemplate>
<asp:HiddenField ID="StateId" runat="server" /><br />
<asp:HiddenField ID="UpdatedRootFolders" runat="server" /><br />
<asp:Button ID="Button1" runat="server" Text="Update RootFolders" OnClick="Button1_Click" />
</ContentTemplate>
</asp:UpdatePanel>
<GleamTech:FileManager ID="fileManager" runat="server" Width="800" Height="600"/>
and in codebehind:
protected void Page_Load(object sender, EventArgs e)
{
StateId.Value = fileManager.StateId;
}
protected void Button1_Click(object sender, EventArgs e)
{
var state = ControlStateManager.GetState<FileManagerState>(StateId.Value);
//Do your root folder modifications here
state.RootFolders.Add(new FileManagerRootFolder { Name = "Test", Location = "/" });
UpdatedRootFolders.Value = JsonConvert.SerializeObject(EnumerateRootFolders(state.RootFolders));
}
private IEnumerable<object[]> EnumerateRootFolders(FileManagerRootFolderCollection rootFolders)
{
for (var i = 0; i < rootFolders.Count; i++)
{
var folder = rootFolders[i].GetFolder(FileManagerAccessControl.Root);
var expandable = folder.CheckPermissions(FileManagerPermissions.ListSubfolders);
var hash = CryptoManager.Hash(rootFolders[i].Location.ToString());
yield return new object[]
{
folder.RootName,
(int)FileManagerPermissions.Full,
"*/",
expandable,
hash
};
}
}
Then I was going to call a client-side method on fileManager instance to load new root folders which are serialized in UpdatedRootFolders hidden field.