質問編集履歴

1

訂正

2019/09/03 14:23

投稿

退会済みユーザー
test CHANGED
File without changes
test CHANGED
@@ -1,85 +1,7 @@
1
- ```ここに言語を入力
2
-
3
- import os
1
+ 間違えました
4
-
5
- import tkinter
6
-
7
- from tkinter import messagebox
8
-
9
- from tkinter import filedialog
10
-
11
-
12
-
13
- root = tkinter.Tk()
14
-
15
- root.title('') #タイトル
16
-
17
- root.geometry('400x200') #サイズ 横x縦
18
-
19
-
20
-
21
- #selctボタンを押したときの処理
22
-
23
- def select_click():
24
-
25
- messagebox.showinfo('select','jsonファイルを選択してください')
26
-
27
- fileType = [('Excelファイル','*.xlsx')] #ファイルタイプをExcelファイルに指定
28
-
29
- iniDir = os.path.abspath(os.path.dirname(ダウン)) #初期表示フォルダ
30
-
31
- filepath = filedialog.askopenfilename(filetypes=fileType,initialdir = iniDir)
32
-
33
- messagebox.showinfo('/Users\yusmi\Downloads\openpose-1.5.0-binaries-win64-only_cpu-python-flir-3d\openpose-1.5.0-binaries-win64-only_cpu-python-flir-3d\ダウン',)
34
-
35
-
36
-
37
- int dx = x2 - x1;
38
-
39
- int dy = y2 - y1;
40
-
41
- double radian = Math.Atan2(dy, dx);
42
-
43
- radian = radian * (180 / Math.PI);
44
2
 
45
3
 
46
4
 
47
5
 
48
6
 
49
-
50
-
51
- #ボタンを作成
52
-
53
- selectButton = tkinter.Button(root, text='File Select',command=select_click)
7
+ こちらの質問が他のユーザから「やってほしいことだけを記載した丸投げの質問」という指摘を受けました 「質問を編集する」ボタンから編集を行い、調査したこと・試したことを記入していただくと、回答が得られやすくなります。
54
-
55
- selectButton.pack()
56
-
57
-
58
-
59
- #ウィンドウを動かす
60
-
61
- root.mainloop()
62
-
63
- ```
64
-
65
-
66
-
67
- ```ここに言語を入力
68
-
69
- File "k.py", line 18
70
-
71
- int dx = x2 - x1;
72
-
73
- ^
74
-
75
- SyntaxError: invalid syntax
76
-
77
- ```
78
-
79
- 選択したjsonファイルの角度を求めたいのですが、中身は座標になっています。
80
-
81
- 求め方が間違っているのだと思うのですが、自身ではわからないため、よろしくお願いいたします。
82
-
83
- tkinterで作成しています。
84
-
85
- windowsです。