D
D
Dimitri Pun2020-12-20 19:33:23
Python
Dimitri Pun, 2020-12-20 19:33:23

Telebot(python) how to make bot only respond to text messages when keyboard is active ?(ReplyKeyboardMarkup)?

How to make the bot react only to the text that is currently on the buttons? That is, when the buttons disappear or are replaced by others, so that the bot does not react to the text from the previous buttons!

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
Mikhail Krostelev, 2020-12-20
@twistfire92

It's easier to use inline buttons. They also look better in the interface.
Well, either start some variable in which you will indicate which keyboard is currently active and whether it is active at all. Depending on this, you already make conditions.
But it's still some kind of stick-rope. Take a closer look at inline buttons.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question