Skip to content

Commit d16ad9c

Browse files
Merge pull request #9 from priyadarshss/main
added set1(week4)
2 parents 0707d1b + 65ed6f5 commit d16ad9c

File tree

1 file changed

+223
-0
lines changed

1 file changed

+223
-0
lines changed

Week 4/SET1.py

Lines changed: 223 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,223 @@
1+
import tkinter as tk
2+
from tkinter.ttk import *
3+
from tkinter.tix import *
4+
5+
window=tk.Tk()
6+
window['background']='#6449C6'
7+
window.geometry('600x800')
8+
9+
window.title("APP")
10+
11+
f1=tk.Label(window, text="FIRST NAME", bg='#6449C6', fg='white', padx=10, pady=15)
12+
f1.place(x=5, y=0)
13+
14+
f1t=tk.Text(window, height=0.8, width=12 )
15+
f1t.place(x=150, y=12)
16+
17+
maxchar1=tk.Label(window, text="(max 30 characters a-z and A-Z)", bg='#6449C6', fg='white', font=("Arial", 8))
18+
maxchar1.place(x=250, y=12)
19+
20+
l1=tk.Label(window, text="LAST NAME", bg='#6449C6', fg='white', padx=10)
21+
l1.place(x=5, y=50)
22+
23+
l1t=tk.Text(window, height=0.8, width=12)
24+
l1t.place(x=150, y=50)
25+
26+
maxchar2=tk.Label(window, text="(max 30 characters a-z and A-Z)", bg='#6449C6', fg='white', font=("Arial", 8))
27+
maxchar2.place(x=250, y=50)
28+
29+
dob=tk.Label(window, text="DATE OF BIRTH", bg='#6449C6', fg='white', pady=15)
30+
dob.place(x=13, y=75)
31+
32+
monthchosen = Combobox(window, width = 7)
33+
daychosen = Combobox(window, width = 7)
34+
yearchosen = Combobox(window, width = 7)
35+
36+
37+
dayl=[]
38+
for i in range(0 ,32):
39+
dayl.append(str(i))
40+
dayl[0]='Day:'
41+
daychosen['values'] = dayl
42+
43+
yearl=[]
44+
for i in range(1968 ,2022):
45+
yearl.append(str(i))
46+
yearl[0]='Year:'
47+
yearchosen['values'] = yearl
48+
49+
monthchosen['values'] = ('Month:',
50+
' January',
51+
' February',
52+
' March',
53+
' April',
54+
' May',
55+
' June',
56+
' July',
57+
' August',
58+
' September',
59+
' October',
60+
' November',
61+
' December')
62+
63+
daychosen.current(0)
64+
daychosen.place(x=150, y=88)
65+
66+
monthchosen.current(0)
67+
monthchosen.place(x=220, y=88)
68+
69+
yearchosen.current(0)
70+
yearchosen.place(x=290, y=88)
71+
72+
e1=tk.Label(window, text="EMAIL ID", bg='#6449C6', fg='white', padx=10)
73+
e1.place(x=5, y=125)
74+
75+
e1t=tk.Text(window, height=0.8, width=12)
76+
e1t.place(x=150, y=125)
77+
78+
l1=tk.Label(window, text="MOBILE NUMBER", bg='#6449C6', fg='white', padx=10, pady=10)
79+
l1.place(x=5, y=150)
80+
81+
l1t=tk.Text(window, height=0.8, width=18)
82+
l1t.place(x=150, y=160)
83+
84+
maxchar3=tk.Label(window, text="(10 digit number)", bg='#6449C6', fg='white', font=("Arial", 8), padx = -100)
85+
maxchar3.place(x=250, y=160)
86+
87+
l1=tk.Label(window, text="GENDER", bg='#6449C6', fg='white', padx=10, pady=10)
88+
l1.place(x=5, y=190)
89+
90+
maxchar3=tk.Label(window, text="Male", bg='#6449C6', fg='white', font=("Arial", 8))
91+
maxchar3.place(x=150, y=200)
92+
93+
tk.Radiobutton(window,value=1, bg='#6449C6').place(x=185,y=200)
94+
95+
maxchar3=tk.Label(window, text="Female", bg='#6449C6', fg='white', font=("Arial", 8))
96+
maxchar3.place(x=225, y=200)
97+
98+
tk.Radiobutton(window,value=2, bg='#6449C6').place(x=270,y=200)
99+
100+
l1=tk.Label(window, text="ADDRESS", bg='#6449C6', fg='white', padx=10, pady=15)
101+
l1.place(x=5, y=225)
102+
103+
l1t=tk.Text(window, height=4, width=18)
104+
l1t.place(x=150, y=240)
105+
106+
f1=tk.Label(window, text="CITY", bg='#6449C6', fg='white', padx=10, pady=15)
107+
f1.place(x=5, y=315)
108+
109+
f1t=tk.Text(window, height=0.8, width=12)
110+
f1t.place(x=150, y=328)
111+
112+
maxchar1=tk.Label(window, text="(max 30 characters a-z and A-Z)", bg='#6449C6', fg='white', font=("Arial", 8))
113+
maxchar1.place(x=250, y=328)
114+
115+
f1=tk.Label(window, text="PINCODE", bg='#6449C6', fg='white', padx=10, pady=15)
116+
f1.place(x=5, y=350)
117+
118+
f1t=tk.Text(window, height=0.8, width=12 )
119+
f1t.place(x=150, y=365)
120+
121+
maxchar1=tk.Label(window, text="(6 digit number)", bg='#6449C6', fg='white', font=("Arial", 8))
122+
maxchar1.place(x=250, y=365)
123+
124+
f1=tk.Label(window, text="STATE", bg='#6449C6', fg='white', padx=10, pady=15)
125+
f1.place(x=5, y=390)
126+
127+
f1t=tk.Text(window, height=0.8, width=12 )
128+
f1t.place(x=150, y=402)
129+
130+
maxchar1=tk.Label(window, text="(max 30 characters a-z and A-Z)", bg='#6449C6', fg='white', font=("Arial", 8))
131+
maxchar1.place(x=250, y=402)
132+
133+
f1=tk.Label(window, text="COUNTRY", bg='#6449C6', fg='white', padx=10, pady=15)
134+
f1.place(x=5, y=428)
135+
136+
countrychosen = Combobox(window, width = 7)
137+
c=["India", "Malaysia", "Japan", "U.S.", "Germany"]
138+
countrychosen['values'] = c
139+
countrychosen.current(0)
140+
countrychosen.place(x=150, y=440)
141+
142+
f1=tk.Label(window, text="HOBBIES", bg='#6449C6', fg='white', padx=10, pady=15)
143+
f1.place(x=5, y=470)
144+
145+
maxchar3=tk.Label(window, text="Drawing", bg='#6449C6', fg='white', font=("Arial", 8))
146+
maxchar3.place(x=150, y=485)
147+
148+
ch1 = tk.Checkbutton(window, bg='#6449C6')
149+
ch1.place(x=195, y=482)
150+
151+
maxchar3=tk.Label(window, text="Singing", bg='#6449C6', fg='white', font=("Arial", 8))
152+
maxchar3.place(x=240, y=485)
153+
154+
ch1 = tk.Checkbutton(window, bg='#6449C6')
155+
ch1.place(x=280, y=482)
156+
157+
maxchar3=tk.Label(window, text="Dancing", bg='#6449C6', fg='white', font=("Arial", 8))
158+
maxchar3.place(x=325, y=485)
159+
160+
ch1 = tk.Checkbutton(window, bg='#6449C6')
161+
ch1.place(x=370, y=482)
162+
163+
maxchar3=tk.Label(window, text="Others", bg='#6449C6', fg='white', font=("Arial", 8))
164+
maxchar3.place(x=150, y=508)
165+
166+
ch1 = tk.Checkbutton(window, bg='#6449C6')
167+
ch1.place(x=195, y=505)
168+
169+
f1t=tk.Text(window, height=0.8, width=12 )
170+
f1t.place(x=220, y=508)
171+
172+
f1=tk.Label(window, text="QUALIFICATION", bg='#6449C6', fg='white', padx=10, pady=15)
173+
f1.place(x=5, y=532)
174+
175+
maxchar3=tk.Label(window, text="Sl.No.\tExamination\tBoard\t\tPercentage\tYear of passing", bg='#6449C6', fg='white', font=("Arial", 8))
176+
maxchar3.place(x=150, y=540)
177+
178+
maxchar3=tk.Label(window, text="1\tClass X \n\n 2\t Class XII \n\n 3\t Graduation\n\n4\tMasters", bg='#6449C6', fg='white', font=("Arial", 8))
179+
maxchar3.place(x=150, y=560)
180+
181+
f1t=tk.Text(window, height=0.8, width=12 )
182+
f1t.place(x=270, y=562)
183+
184+
f1t=tk.Text(window, height=0.8, width=12 )
185+
f1t.place(x=375, y=562)
186+
187+
f1t=tk.Text(window, height=0.8, width=12 )
188+
f1t.place(x=480, y=562)
189+
190+
f1t=tk.Text(window, height=0.8, width=12 )
191+
f1t.place(x=270, y=588)
192+
193+
f1t=tk.Text(window, height=0.8, width=12 )
194+
f1t.place(x=375, y=588)
195+
196+
f1t=tk.Text(window, height=0.8, width=12 )
197+
f1t.place(x=480, y=588)
198+
199+
f1t=tk.Text(window, height=0.8, width=12 )
200+
f1t.place(x=270, y=614)
201+
202+
f1t=tk.Text(window, height=0.8, width=12 )
203+
f1t.place(x=375, y=614)
204+
205+
f1t=tk.Text(window, height=0.8, width=12 )
206+
f1t.place(x=480, y=614)
207+
208+
f1t=tk.Text(window, height=0.8, width=12 )
209+
f1t.place(x=270, y=640)
210+
211+
f1t=tk.Text(window, height=0.8, width=12 )
212+
f1t.place(x=375, y=640)
213+
214+
f1t=tk.Text(window, height=0.8, width=12 )
215+
f1t.place(x=480, y=640)
216+
217+
b=tk.Button(window, text="Submit", bd = '5')
218+
b.place(x=320, y=665)
219+
220+
b=tk.Button(window, text="Reset", bd = '5')
221+
b.place(x=400, y=665)
222+
223+
window.mainloop()

0 commit comments

Comments
 (0)