I want to delete a directory through python and the cmd window but i want it to open the command do the rd and then close and continue on with the program with out me having to type RD /s folderName

Use os.system("RD /s folderName") or subprocess.Popen depending on your python install

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.