N
N
NNull2020-09-06 04:44:53
Python
NNull, 2020-09-06 04:44:53

How to change only text without reply_markup?

How to use edit_message_text to change only the text without affecting the inlinekeyboard ?
That is, the message that needs to be changed already has an inlinekeyboard, you only need to change the text without affecting (saving) the keyboard itself.
This method does not work:

bot.edit_message_text(
            message_id=call.message.message_id,
            chat_id=call.message.chat.id,
            text=answer,
            parse_mode='html'
        )

Answer the question

In order to leave comments, you need to log in

1 answer(s)
I
IKIQ, 2020-09-06
@IKIQ

And if you just call inlinekeyboard again in bot.edit_message_text ?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question