Skip to content

Commit 0179526

Browse files
author
espen.steen
committed
Renamed fetcher filename
1 parent 99a83f2 commit 0179526

File tree

2 files changed

+11
-6
lines changed

2 files changed

+11
-6
lines changed

gui.py

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -133,14 +133,19 @@ def click_button_open_file_explorer():
133133

134134
def click_button_copy_fetcher_script():
135135
try:
136-
with open("CRMScript Fetcher.crmscript") as f:
136+
with open("crmscript_fetcher.crmscript") as f:
137137
app.clipboard_clear()
138138
app.clipboard_append(f.read())
139139
except FileNotFoundError:
140-
messagebox.showerror("Could not copy fetcher script to clipboard",
141-
"Could not find the fetcher script."
142-
" The script must be in this app's root folder"
143-
" with the name \"CRMScript Fetcher.crmscript\".")
140+
try:
141+
with open("CRMScript Fetcher.crmscript") as f:
142+
app.clipboard_clear()
143+
app.clipboard_append(f.read())
144+
except FileNotFoundError:
145+
messagebox.showerror("Could not copy fetcher script to clipboard",
146+
"Could not find the fetcher script."
147+
" The script must be in this app's root folder"
148+
" with the name \"crmscript_fetcher.crmscript\".")
144149

145150

146151
# OTHER FUNCTIONS
@@ -321,7 +326,7 @@ def create_widgets(self):
321326
text="Save settings",
322327
command=click_button_save,
323328
style="TButton",
324-
state=DISABLED,)
329+
state=DISABLED, )
325330

326331
button_save.grid(row=6, column=0, sticky="w")
327332

0 commit comments

Comments
 (0)