skip to Main Content

My goal is to create as many buttons as amounts of users with their names (SQL) , but problem is i don’t know the name of the function that cleans keyboard every time I call it

async def set_kb():
    # here should be function
    for i in db_show_players():
        in_group_kb_players.add(InlineKeyboardButton(text=str(i[0]), callback_data=i[1]))

I tried .clean() but it didn’t work

2

Answers


  1. Chosen as BEST ANSWER

    I solved that. solution was simple damn.. there is no function that clears the keyboard so the variable should be local. in my case i imported that into other module which created this bug.


  2. await message.answer(content["Text"], reply_markup=types.ReplyKeyboardRemove())
    
    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search