Uploadding Document
Hi,
I am trying to write code for Uploading a Document(.txt,.pdf)
using Telerik.Sitefinity.Libraries.Model; using Telerik.Sitefinity.Modules.Libraries;
i read in the sitefinity blog that i have to use these namespaces, but i am not able to get these,
the only namespace i got is
using Telerik.Sitefinity
i am using the following things in my code,
LibrariesManager libManager = LibrariesManager.GetManager(); //get parent document library DocumentLibrary docLib = libManager.GetDocumentLibraries().FirstOrDefault(); Document document = libManager.CreateDocument(); But how to get the above mentioned namespaces?
Is this for a sitefinity project or custom module/widget?
If its for a project the namespaces should be available, if its for a module/widget then you may need to add a reference to the Telerik.Sitefinity.dll from the empty_projects folder of your installation, weird that its not appearing though, this should be as standard.
Rob
This is for Custom Widget, i am using Telerik.Sitefinity Namespace but the other namespaces are not available also the dll also not available.
Hi SP,
You need to include the Telerik.Sitefinity.dll into the widget project you are working on. If you have installed the SDK then you should have an _emptyProject folder in the telerik -> sitefinity folder under program files, in there, there should be a bin directory with all the dlls, and you nee to add the reference from within visual studio, you ned to browse to that directory and add it.
Image attached showing where mine is.
Rob
i don't have that path on my C:\ OR D:\ either
Log into you account, download and install the SDK.