初質問の初心者です。よろしくお願いいたします。
実現したいこと
各国通貨を1ユーロ当たりの値に変換するアプリをTkinterで作成
発生している問題・エラーメッセージ
http://www.floatrates.com/daily/eur.json
上記のjsonを使用して、変換を行う関数とその結果を反映するところがまだ理解しておらず、手が止まっております。
該当のソースコード
python
import tkinter as tk import tkinter.ttk as ttk from turtle import back win = tk.Tk() win.geometry('500x400') win.config(bg='lightgray') win.title('FX Lookup') label1 = tk.Label(win, text='Exchange Rate Lookup | Show exchange rates from EUR to various other currencies.', font=('Basic', 13), background='lightgray', wraplength=450, justify='left') label1.place(x=10, y=30) label2 = tk.Label(win, text='Example currency symbols: USD, HKD, INR, GBP, ...', font=('Basic', 13), background='lightgray') label2.place(x=10, y=95) separator_gray = ttk.Separator(win, style="gray.TSeparator", orient='horizontal') separator_gray.pack(padx=10, pady=160, fill='x') label3 = tk.Label(win, text='Currency symbol', font=('Basic', 13), background='lightgray') label3.place(x=175, y=170) label4 = tk.Label(win, text='1 EUR = ', background='lightgray', font=('Basic', 13)) label4.place(x=220, y=200) label5 = tk.Label(win, text=str(0), font=('Basic', 13), background='lightgray') label5.place(x=400, y=200) def convert(): pass txtBox = tk.Entry(width=22, font=('Basic', 13)) txtBox.place(x=10, y=200) button = tk.Button(text="Lookup", command=convert, width=52, background='lightgray', font=('Basic', 13)) button.place(x=10, y=230) win.mainloop()
補足情報
python 3.10.4
Visual Studio Code 1.66.0
Windows 11
まだ回答がついていません
会員登録して回答してみよう