Free Support Forum - groupdocs.com

How to set file path dynamically


#1

Hi,


I have downloaded sample code of GroupDocs.Viewer for .Net. In, GroupDocsViewerWebformDemo application, how to set file path dynamically.

Thanks,
Bhaskar V



#2

Hello Bhaskar,

Thank you for your interest in GroupDocs. Please tell us more about your use-case, because it’s hard to understand what exactly you mean under the “dynamically”. What kind of dynamically are you requiring?

If you are wondering about the root storage, which is installed using the “Groupdocs.Web.UI.Viewer.SetRootStoragePath” method, then this method can be invoked in any place of your application, not only in the Global.asax. The only requirement - root storage should be initialized before first use of the GroupDocs.Viewer widget.

At the one particular moment of time only one root storage can be present, you cannot have multiple root storages simultaneously. If you invoke “Groupdocs.Web.UI.Viewer.SetRootStoragePath” method several times, then root storage will be re-setted after each invoke.

Thanks and waiting for your clarification.