FileStorage in SQL DB problem

  •  01-17-2009, 3:28 PM

    FileStorage in SQL DB problem

    Hi,
    I have CE editor control inside EditTemplate in FormView and I'm using SQL DB as filesystem storage for everything. (SQL2008+.Net 3.5)
    The problem is that inserting images/Downloadable files works only one time: I can select an file/image, insert it in CE and save the content.
    But when I click an 'image gallery", "iNSERT iMAGE" or "Downloadable files" button again, I'm getting System.IO.DirectoryNotFoundException...
    It looks like CE tried to access upload folder in filesystem, instead of my DB....
    Sure, I reinitialize the following properties on Page_Load:
     Editor1.Setting["CuteEditorFileStorageType"] = typeof(CuteEditorSqlFileStorageProvider).AssemblyQualifiedName;
     Editor1.Setting[
    "DownFile"] = ResolveUrl("DownFile.Aspx");
     Editor1.SetSecurityGalleryPath(
    "/");
     
    Here is the exception: (part of the filesystem path is replaced with xxxxx)

    Could not find a part of the path xxxxxxxxx\uploads'.

    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details: System.IO.DirectoryNotFoundException: Could not find a part of the path xxxxxx\uploads'.

    Source Error:

    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

    Stack Trace:

    [DirectoryNotFoundException: Could not find a part of the path 'xxxxxxxxx\uploads'.]
                System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) +193
                System.IO.Directory.InternalGetFileDirectoryNames(String path, String userPathOriginal, String searchPattern, Boolean includeFiles, Boolean includeDirs, SearchOption searchOption) +1923
                System.IO.Directory.GetDirectories(String path, String searchPattern, SearchOption searchOption) +37
                System.IO.Directory.GetDirectories(String path) +14
                CuteEditor.Impl.FileSystemStorage.GetDirectoryItems(String dirpath, Boolean getcount) +70
                CuteEditor.Dialogs.InsertGalleryFrame.b() +842
                CuteEditor.Dialogs.InsertGalleryFrame.OnLoad(EventArgs e) +45
                System.Web.UI.Control.LoadRecursive() +50
                System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +627
                
     

    Version Information: Microsoft .NET Framework Version:2.0.50727.3053; ASP.NET Version:2.0.50727.3053
     
    What am I doing wrong?
    Any help would be greatly appreciated.
     
    Boris
View Complete Thread