Skip to main content
Stack Overflow for Teams is now Stack Internal: See how we’re powering the human intelligence layer of enterprise AI. Read more >
Filter by
Sorted by
Tagged with
8 votes
0 answers
394 views

Is there a safe way to create directories with std::filesystem?

I have compared the description of POSIX mkdir against the description of std::filesystem::create_directory, the specification draft for std::filesystem::create_directory, and the specification draft ...
Adam Badura's user avatar
  • 5,533
1 vote
1 answer
463 views

Fileystem API showDirectoryPicker() permanently broken if user doesn't choose a directory in Electron

This issue occurs in the latest version of Electron, but not in Chromium outside of Electron. The following example code uses the Filesystem API's showDirectoryPicker method to open a directory-picker ...
twhitney's user avatar
  • 365
0 votes
1 answer
39 views

Python Issue making folder outside of current directory

So I'm able to create folders in the same path as my main.py is in. But even with using os.chdir and try to create an folder into that directory I'm unable to. It can read if an folder like that exist ...
David Young's user avatar
-2 votes
1 answer
140 views

best method: check if it would be possible to create and write to a folder

I need to know if a folder might be created or blocked e.g. by a wrong part of the dir parameter. Is there a better solution to check if I can (at a later point of time) create a folder and write to ...
Franz's user avatar
  • 2,067
2 votes
0 answers
2k views

How can I use Tauri to create a directory in a user-selected directory?

When I use the createDir method in Tauri + Typescript, I have to specify a base directory (dir) in the FsDirOptions. But I want to give the user himself the possibility to choose a target directory. ...
eddieconnecti's user avatar
1 vote
0 answers
32 views

Copy file along with creating directory

I have a file in the directory as /a/b/c/xxxxx.sql I have anorther directory /a/b/d, having no further sub directories How should I copy xxxxx.sql into /a/b/d, to have the new file with directory as /...
Siddharth Somani's user avatar
1 vote
1 answer
979 views

Create Directories with File permissions - Java

I'm trying to create Directories locally with specific permissions, but it doesn't work in some cases and reverts to specific permissions. This is my code Path path = Paths.get(dir); Set&...
Stan's user avatar
  • 21
1 vote
1 answer
1k views

Create config directory in linux with Rust

Started learning rust yesterday so im a complete newbie. I wanted to make a command line program for linux as my first project. I want it so when you run the program it checks if the config directory ~...
farima4's user avatar
  • 23
0 votes
1 answer
85 views

NodeJS - Create a new numbered subdirectory based on the last element of an array based subdir list (Closed)

I have this function that reads a specified working directory using fs.readdir, which then filters out all files and returns an array based list of the first set of subdirectories within the specified ...
Morsmalleo's user avatar
0 votes
1 answer
587 views

Unable to create new folder with SystemFileObject in VBA

I'm trying to create a new folder in the same folder that my workbook is in, but I keep running into run-time error '52': "Bad file name or number". Does somebody have an idea on how to fix ...
Suraido's user avatar
  • 11
1 vote
1 answer
96 views

GitHub API not creating directories correctly using Python

I'm using the Github API and Python to attempt to generate a file structure in a repository, but the directories aren't forming correctly. To authenticate and create the repository, I'm using the ...
OrbitalMartian's user avatar
0 votes
0 answers
77 views

Create A folder in Internal memory of phone using Android studio

package com.example.pdfscanner; import androidx.annotation.NonNull; import androidx.annotation.Nullable; import androidx.annotation.RequiresApi; import androidx.appcompat.app.AppCompatActivity; ...
044_Harshvardhan Singh's user avatar
0 votes
2 answers
4k views

SpecialFolder.ApplicationData not working in .net MAUI?

I cannot get my directories made to AppData/Roaming while using this code in .net MAUI: RootLocation = new DirectoryInfo(GetFolderPath(SpecialFolder.ApplicationData) + "/MyApp"); ...
DaWiseguy's user avatar
  • 1,046
0 votes
1 answer
2k views

vscode.workspace.workspaceFolders[0].uri.fsPath running an error called object is undefined?

I was developing VS code extension and try to create and add files/folders into the workspace. But there was an error came up "Object is possibly 'undefined'.ts(2532)". I am using latest ...
Hirush Gimhan's user avatar
-1 votes
1 answer
396 views

How to create directory in android 11 and above like Telegram

I am trying to create a folder in device internal storage like the same way telegram and WhatsApp does in Android 11 and above devices without using manage access all files permission. any reference ...
Suraj pal's user avatar
2 votes
2 answers
5k views

Create new Folder in OneDrive

Been using code below for years. It creates new folder, and names it to next work-day's date + adds another folder within this, named "VO". Code got two "fPath"-lines. The one at ...
user avatar
0 votes
1 answer
2k views

Copy Just the Folder

I wanted to Copy just a single folder at a time from one location to another Currently i hv to First go to the rename copy the name and come back to current location and create a new folder and paste ...
Himusaki Maguro's user avatar
1 vote
1 answer
222 views

Saving pictures to a new folder each iteration in Python

I practice my web scraping skills in Python and Selenium library. My goal is to download images from a real estate website (comparis.ch). I have a list of links where each link is an apartment. I want ...
Stash's user avatar
  • 15
1 vote
1 answer
142 views

Copy file to newly created directories

So I have a bit complicated one, I'm trying to create a "template creator". User will input data via comboboxes and textboxes into a form, from which a button generates the names (...
Jaymar's user avatar
  • 27
0 votes
2 answers
232 views

Python: How to makedirs from an excel file containing paths?

How do I generate folders using the contents of my excel document? I have been coding this for awhile and I just cannot seem to get it to work. My objective is to create folders using an excel ...
PythonStarter's user avatar
0 votes
1 answer
644 views

How to make a folder and subfolder with `FileSystemObject.CreateFolder` at the same time [duplicate]

Top macro works, bottom one doesn't unless I run the top one first. How do I create folder & subfolder concurrently? I'm trying to use FileSystemObject.CreateFolder to make a folder and subfolder ...
user1636620's user avatar
0 votes
1 answer
1k views

How to create a subfolder of a Uri folder, Android 10+?

It was here before SDK 29, but now it is required. My app creates a cascade of folders to manage its content. All the content is meant to be stored inside any folder the user chooses, but for the ...
JosefLitos's user avatar
0 votes
1 answer
178 views

How to Save Images from ImageView in specific Folder from Whatsapp .Status Folder in Android 11

I like to save Images Which I take from .status Folder from Whatsapp So I would like to know How to access .Status Folder of Whatsapp and Save that Image in My own define Folder in Android 11 (Scope ...
Minhal Zafar's user avatar
1 vote
0 answers
264 views

VBScript does not oFS.FileExists a file in oFS.CreateFolder

I'm having a strange problem with VBScript. I'd like to implement some other code with a following test: If there is a file named like [that] in the [folder], do not copy it into the [folder]. Thing ...
Mateusz's user avatar
  • 23
0 votes
1 answer
278 views

Create folder based on filename

I have a question how to create a new folder based on part of the filename and also move directly the corresponding files to the new folder. Below you will find the structure of my directory with some ...
raveleijn1952's user avatar
2 votes
2 answers
388 views

Create same folders in different subdirectories in R

I try to create the same folders in multiple subdirectories in R. I thought I could do this with a for loop, but it did not go as planned My folder structure is like this: Main directory/Weather_day . ...
raveleijn1952's user avatar
0 votes
1 answer
172 views

onActivityResult Uri - create subfolder and get DocumentUri of new subfolder

I take the result of my file chooer in onActivityResult an build a DocumentUriUsingTree. Now I take this DocumentUri, build a DocumentFile to create a new folder. onActivityResult: if (resultCode == ...
Alejandro Gomez's user avatar
0 votes
0 answers
330 views

How to create new folder in powerpoint using VBA?

I'm trying to get this macro to save my powerpoint slides as pdf in new folder, that is not created beforehand. Problem is that it seems like MkDir doesn't create the root folder, but rather folder ...
dibledurf's user avatar
1 vote
1 answer
2k views

In C#, how can I create a folder if it does not exist on a SharePoint site

I am trying to create a microservice in C# which will accept a csv file containing order numbers, digest the csv, connect to sharepoint, create a new folder on sharepoint, and then copy contracts with ...
Brian Kessler's user avatar
0 votes
1 answer
122 views

I need create a new folder when visiting new users into my website using thier ip - php

I need create folders to all users who visiting my website using their ip address. the folder name should be "user_ipaddress". so i have this kind of code. it's creates this kind of folders &...
Tharuka Dananjaya's user avatar
3 votes
1 answer
3k views

How to create folder automatically before files upload via multer so that those files get stored in that created folder in nodejs?

This is my multer code to upload multiple files. var storage = multer.diskStorage({ destination: function (req, file, cb) { cb(null, './public/files/'+ req.user.id) }, filename: function (...
Biku7's user avatar
  • 470
0 votes
0 answers
1k views

java.io.IOException: unable to create directory: /tokens Google Sheet API

I finally follow the google sheet quickstart and done the sample application. Now I want to call the API to create a sheet, however, the error shows: java.io.IOException: unable to create ...
Penny Chen's user avatar
1 vote
2 answers
2k views

Create Folder based on cell value

I made below code to create multiple folder based on cell value but i want that path should also picked from the cell. I have folder path in F4. so instead of folder path i want to add F4 in code. ...
Rahul Aggarwal's user avatar
-1 votes
1 answer
169 views

Question about File Paths and opening those files C#

I have Three strings that are set to the current: year, month, day respectively using the "DateTimeNow". and I have set a path to a string of the root folder named "Custom_project" ...
Jaydon's user avatar
  • 49
0 votes
0 answers
34 views

Php function that create a new folder with the part of the name of a file

I really hope that you will help with this. Well, I have a folder full of files which has name like this : AZERRKDKD_00000.csv AZERKRJFJDD_0000.csv … I am looking for a script that can help me to ...
Sara ATINE's user avatar
1 vote
1 answer
2k views

Win32 CreateDirectory fails with multiple folders in a long path

The environment is Windows 7 Pro and Delphi 7. Windows.CreateDirectory() is failing to create multiple folders in a very long path that is well under the path length limit. GetLastError() returns ...
Bruce Gavin's user avatar
0 votes
0 answers
101 views

Macro to save file to folder depending on month and customer

I have the follwoing code: ActiveWorkbook.ExportAsFixedFormat Type:=xlTypePDF, Filename:="U:\sales\Quotes test\" & Range("s2").Value & ".pdf" _ , Quality:=xlQualityStandard, ...
CharlieBea's user avatar
0 votes
1 answer
120 views

Batch File to organise pictures from mobile phone into folders (on Windows)

I just created my first Batch file, to organise my mobile phone pictures into folders (on Windows). It worked, I am just wondering if there is a more efficient way in coding this, as in its current ...
Ben's user avatar
  • 13
0 votes
1 answer
239 views

Applescript/Finder - how to check if a variable folder exists within a fixed folder

I'm trying to get the script to check if there is a variable folder name, eg. "folder x", present from within a folder that has folders a-z for example? The rest of the script works fine but the ...
l0g0p7's user avatar
  • 1
0 votes
2 answers
772 views

The expression must have a class type

I am currently programming a patching application for my game. As i am used to program with Java its hard for me to get along with C++, the patcher has to be wridden in C++ unfortunately, in Java i ...
RAVN Mateus's user avatar
0 votes
1 answer
456 views

C# Folder creation not creating all folders, but only on some machines

I'm writing a custom application for work. The application will create a folder structure for our client projects. The machine I am creating the program on works both while in debug from the code ...
Soul Existence's user avatar
-2 votes
1 answer
585 views

Create a folder and subfolder when selecting a cell

I am a total newbie in VBA so I hope you could help me with this. I want to create a folder inside a given path. Inside the folder, I want a subfolder. The name of the folder will be indicated in ...
utzerc's user avatar
  • 1
0 votes
1 answer
368 views

Copy file with certain name into a new folder

I have a powershell script that will search through the sub folders of a directory and copy any files that contain a specific string in the name and then move those into a different folder that it ...
ThisGuyUsesPowershell's user avatar
0 votes
2 answers
150 views

How to create a folder programmatically in Android

I wonder how you (C#)programmatically create a folder in the Assets Folder in Android. My project is called App1 so the folder I want to create is named: "imagefolder1" The full path look like this: ...
Andreas's user avatar
  • 1,295
0 votes
1 answer
1k views

How to save path of a file and use the path in browse button in C# windows application

In C# windows application, i have a textbox1 and "create folder" button and "Open created folder!" buttons. when, i give a name to textbox1 and press "create folder", a folder create with that name. ...
Flash's user avatar
  • 87
1 vote
1 answer
3k views

Generating more than 1 directory with a single os.mkdir function (Python)

I made a function in Python (WinOS) that ends up creating new directories (where future work is stored). So at some point, I define the directories and after I use os.mkdir(os.pahth.join('current_dir',...
joueswant's user avatar
  • 146
3 votes
1 answer
1k views

How to resolve NoSuchFileException for Files.createDirectories

On a production Linux env, Im getting NoSuchFileException for Files.createDirectories api. I have checked the java docs for Files.createDirectories and it inherently does not throw this exception. I ...
bhavesh patidar's user avatar
0 votes
1 answer
78 views

Create new existent folder with an identifier like folder_1, folder_2 etc.. with python

I'm creating a new component for my code that can create copies of a folder with an identifier. For example, I have a serial number and I'm creating a new folder for every serial number, inside every ...
Rubicelia Patlán's user avatar
5 votes
1 answer
7k views

Create folders dynamically and write csv files to that folders

I would like to read several input files from a folder, perform some transformations,create folders on the fly and write the csv to corresponding folders. The point here is I have the input path which ...
The Great's user avatar
  • 7,783
0 votes
2 answers
1k views

CreateDirectory in Environment.SpecialFolder.MyDocuments is denied

I have a file stream that I want to store in iOS under a subfolder under the SpecialFolder enum. The FileStream constructor wants the subfolder structure to exist first and when I try to create it, I ...
John Mc's user avatar
  • 223