-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsystem_folder.py
60 lines (41 loc) · 1.45 KB
/
system_folder.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
import os
from speak import speak
import subprocess
#fuctions to open system folder
def open_documents():
try:
# os.startfile('C:\\Users\\Vivek Kumar Goel\\Documents')
subprocess.Popen('explorer "C:\\Users\\Vivek Kumar Goel\\Documents" ')
except Exception as e :
speak("No such folder found in the main directory")
def open_downlaods():
try:
os.startfile("C:\\Users\\Vivek Kumar Goel\\Downlaods")
except Exception as e :
speak("No such folder found in the main directory")
def open_music():
try:
os.startfile("C:\\Users\\Vivek Kumar Goel\\Music")
except Exception as e :
speak("No such folder found in the main directory")
def open_pictures():
try:
os.startfile("C:\\Users\\Vivek Kumar Goel\\Pictures")
except Exception as e :
speak("No such folder found in the main directory")
def open_videos():
try:
os.startfile("C:\\Users\\Vivek Kumar Goel\\Videos")
except Exception as e :
speak("No such folder found in the main directory")
def open_screenshots():
try:
os.startfile("C:\\Users\\Vivek Kumar Goel\\Pictures\\Screenshots")
except Exception as e :
speak("No such folder found in the main directory")
#function to close system folder
def close_documents():
file.terminate()
if __name__ == "__main__":
open_documents()
close_documents()