Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeDevelopment and...Development and...Building ExtensionsBuilding ExtensionsModulesModulesDotNetNuke Module File ManagementDotNetNuke Module File Management
Previous
 
Next
New Post
8/10/2011 4:58 PM
 
cathal connolly wrote:
you'll have to do a syncronize so that dotnetnuke picks up the files in the folders (either via the UI or via the API) - im not sure why the subfolders would show twice-is that the case in the actual filesysyem (also please check that you are not accidentally calling the method to add folder data to the database -the filesystemutils.upload method does that as part of it's work as well as validating other settings)

 I did a synchronization and it didn't do anything. This only appears in the file manager, its not in the file system.

I am confused by your last comment the most though. I shouldn't add folders? If I don't add the folders before calling upload then I get cannot access folder errors.

I am attempting to create a top level folder for the module called DataValidation. Underneath it each instance of the module creates its own folder to organize everything. I can upload to the top level folder fine, its only the subfolders that are acting strange.

Can you give me some code to work with? Heres an overview of what I am attempting (pseudocode).

if(!moduleFolderExists)
FileSystemUtils.AddFolder(PortalSettings, PortalSettings.HomeDirectoryMapPath, "DataValidation\\");

If(!instanceFolderExists)
FileSystemUtils.AddFolder(PortalSettings, PortalSettings.HomeDirectoryMapPath + "DataValidation\\", "SubfolderName");

btnUpload_click
string path = PortalSettings.HomeDirectoryMapPath + "DataValidation\\SubfolderName\\"
string s = FileSystemUtils.UploadFile(path, uploadedFile);

 
New Post
8/11/2011 3:33 AM
 
you might need to perform a recursive sync after adding the folders, if they don't show up in file manager, prior to uploading the file.

Cheers from Germany,
Sebastian Leupold

dnnWerk - The DotNetNuke Experts   German Spoken DotNetNuke User Group

Speed up your DNN Websites with TurboDNN
 
New Post
8/11/2011 12:07 PM
 
Sebastian Leupold wrote:
you might need to perform a recursive sync after adding the folders, if they don't show up in file manager, prior to uploading the file.

 Code please?
How do you do this? All the methods I can see within FileSystemUtils related to syncing are deprecated and I cannot find any help documents that go over how to do this.

 
New Post
8/11/2011 1:57 PM
 
I also just tried recursive syncing manually in the file manager and it just got more confused. Now multiple versions of the folder are displayed in the file manger and they all point to the same place. One is at the top level. Another is in the right place, and another "folder" is within the subfolder. I'm not sure what is going on there at all.

This seems like an incredibly simple problem. All I want to do is:
1. Create root level folder.
2. Create subfolder.
3. Upload file to subfolder

What code is required to do this?
 
Previous
 
Next
HomeHomeDevelopment and...Development and...Building ExtensionsBuilding ExtensionsModulesModulesDotNetNuke Module File ManagementDotNetNuke Module File Management


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out