The Coding Experience
Would you like to react to this message? Create an account in a few clicks or log in to continue.

As we have decided, our forum will no longer be active. We'll close our community on Feb, 5. Thanks for those who were with us. Bye. ~ ADMIN.
Search
Display results as :
Advanced Search
Top posting users this week
No user
[DJANGO - .PY] Trouble when trying to run manage.py
Mon Oct 09, 2017 9:42 amJoao
I was trying to run manage.py runserver, but with no success, anyone has any solution ???
[DJANGO - .PY] HOW TO FIX THE "STARTPROJECT" SYNTAX ERROR
Fri Oct 06, 2017 1:13 pmRenan Araújo
Its very common to run the command
Code:
django-admin.py startproject xxx
*xxx stands for the name of your project

But when you get an error and you dont know how to fix, an error saying that "startproject" is an invalid syntax.
So, its simple to solve, you just need to copy the code below, AND SAVE IT AS anything.BAT, MUST PUT .BAT in the end.
Code:
@echo off
@echo Made by TCE Forum ! ! !
@echo  …
[.PY - TKINTER] Mini guessing game using an interface
Thu Oct 05, 2017 3:05 pmRenan Araújo
Code:
from tkinter import *
class MyApp(Frame):
    def __init__(self, master=None):
        Frame.__init__(self, master)
        self.pergunta = Label(self, text='Brazil was discovered in:', fg='red')
        self.pergunta.pack()
        self.botao1 = Button(self, text='A:\n1490', background='green',
                 …
[PYTHON] - Simple loadin using for
Thu Oct 05, 2017 9:57 amJoao
As i am newbie in coding, i would like to share something, isnt much thing, simply a loading, very simple.

Code:
Loading = ['L','O','A','D','I','N','G']
    for L in Loading:
        time.sleep(1)
        print(L)
    print('DONE !')
Registration and Login System with PHP and MySQL
Thu Oct 05, 2017 9:51 amJoao
*CREDITS: codexworld <3

Database Table Creation

A table is needed to store the user details in the database. The following SQL creates a users table with some required columns.

Code:
CREATE TABLE `users` (
 `id` int(11) NOT NULL AUTO_INCREMENT,
 `first_name` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
 `last_name` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
 …
Django - Python
Tue Oct 03, 2017 3:10 pmRenan Araújo
As many people think, web development is not that hard, by learning with the right guides ( just talking about learning by yourself on the internet ), you won't have troubles.
A good way to learn is by reading this PDF ( <- click here )
[PYTHON] Change the ID with a new user
Wed Oct 04, 2017 2:08 pmJoao
A simple code ( very simple Mad ) to change the actual ID, to the next, when a new user enter, here's the code:

Code:
 """
CHANGING ACTUAL ID """
ID_Actual = 0
while 1:
    User_Actual = input('Type the username:  ')
    User_ID_Actual = ID_Actual
    print('USER: {}'.format(User_Actual))
    print('ID: …

Go down
Renan Araújo
Renan Araújo
:
:
Posts : 16
Points : 2448
Reputation : 15
Join date : 2017-10-03
Location : Brazil
http://thecodingexperience.tk

[.PY - TKINTER] Mini guessing game using an interface Empty [.PY - TKINTER] Mini guessing game using an interface

Thu Oct 05, 2017 3:05 pm
Code:
from tkinter import *
class MyApp(Frame):
    def __init__(self, master=None):
        Frame.__init__(self, master)
        self.pergunta = Label(self, text='Brazil was discovered in:', fg='red')
        self.pergunta.pack()
        self.botao1 = Button(self, text='A:\n1490', background='green',
                             command=self.escolhaA)
        self.botao1.pack()
        self.botao2 = Button(self, text='B:\n1628', background='yellow',
                             command=self.escolhaB)
        self.botao2.pack()
        self.botao3 = Button(self, text='C:\n1500', background='black',
                             fg='white', command=self.escolhaC)
        self.botao3.pack()
        self.pack()
    def escolhaA(self):
        print('Wrong dude !\n:(')
    def escolhaB(self):
        print('Wrong dude !\n:(')
    def escolhaC(self):
        print('Right !!!\n:D')
app = MyApp()
app.master.title('Guessing Game')
app.master.geometry('400x400+300+300')
mainloop()

*** Remember that you dont need to use "background", if you like simple and short things, just replace it for "bg".
And "fg" stands for the color of the font used.
Joao
Joao
:
:
Posts : 12
Points : 2393
Reputation : 4
Join date : 2017-10-03

[.PY - TKINTER] Mini guessing game using an interface Empty Re: [.PY - TKINTER] Mini guessing game using an interface

Thu Oct 05, 2017 3:36 pm
Renan Araújo wrote:
Code:
from tkinter import *
class MyApp(Frame):
    def __init__(self, master=None):
        Frame.__init__(self, master)
        self.pergunta = Label(self, text='Brazil was discovered in:', fg='red')
        self.pergunta.pack()
        self.botao1 = Button(self, text='A:\n1490', background='green',
                             command=self.escolhaA)
        self.botao1.pack()
        self.botao2 = Button(self, text='B:\n1628', background='yellow',
                             command=self.escolhaB)
        self.botao2.pack()
        self.botao3 = Button(self, text='C:\n1500', background='black',
                             fg='white', command=self.escolhaC)
        self.botao3.pack()
        self.pack()
    def escolhaA(self):
        print('Wrong dude !\n:(')
    def escolhaB(self):
        print('Wrong dude !\n:(')
    def escolhaC(self):
        print('Right !!!\n:D')
app = MyApp()
app.master.title('Guessing Game')
app.master.geometry('400x400+300+300')
mainloop()

*** Remember that you dont need to use "background", if you like simple and short things, just replace it for "bg".
And "fg" stands for the color of the font used.

and if i want to delete one button, for example, the right is C, but when user click on A or B, what i have to do ?
Renan Araújo
Renan Araújo
:
:
Posts : 16
Points : 2448
Reputation : 15
Join date : 2017-10-03
Location : Brazil
http://thecodingexperience.tk

[.PY - TKINTER] Mini guessing game using an interface Empty Re: [.PY - TKINTER] Mini guessing game using an interface

Thu Oct 05, 2017 3:38 pm
Message reputation : 100% (1 vote)
for example:
Code:
self.botao2 = Button(self, text='B:\n1628', background='yellow',
                            command=self.escolhaB)
just use .destroy()

Code:
self.botao2.destroy()
Joao
Joao
:
:
Posts : 12
Points : 2393
Reputation : 4
Join date : 2017-10-03

[.PY - TKINTER] Mini guessing game using an interface Empty Re: [.PY - TKINTER] Mini guessing game using an interface

Thu Oct 05, 2017 3:40 pm
what about using another interface module ? do you know any thats easier ?
Renan Araújo
Renan Araújo
:
:
Posts : 16
Points : 2448
Reputation : 15
Join date : 2017-10-03
Location : Brazil
http://thecodingexperience.tk

[.PY - TKINTER] Mini guessing game using an interface Empty Re: [.PY - TKINTER] Mini guessing game using an interface

Thu Oct 05, 2017 3:43 pm
Message reputation : 100% (1 vote)
Joao wrote:what about using another interface module ? do you know any thats easier ?

For me, TKinter is the coolest and the best to use, and it would be more welcomed as you are learning to code interfaces.
Take a look at python docs about TK, i'm sure you'll like it.
Joao
Joao
:
:
Posts : 12
Points : 2393
Reputation : 4
Join date : 2017-10-03

[.PY - TKINTER] Mini guessing game using an interface Empty Re: [.PY - TKINTER] Mini guessing game using an interface

Thu Oct 05, 2017 3:47 pm
Renan Araújo wrote:
Joao wrote:what about using another interface module ? do you know any thats easier ?

For me, TKinter is the coolest and the best to use, and it would be more welcomed as you are learning to code interfaces.
Take a look at python docs about TK, i'm sure you'll like it.

So i'll take a look, and after i get in touch
Sponsored content

[.PY - TKINTER] Mini guessing game using an interface Empty Re: [.PY - TKINTER] Mini guessing game using an interface

Back to top
Permissions in this forum:
You cannot reply to topics in this forum