From 1f7a9900c48ecb2a8a5e0e48dd35590bb43560ef Mon Sep 17 00:00:00 2001 From: FlorianDahn Date: Sat, 17 Jul 2021 18:36:56 +0200 Subject: [PATCH] Updating TelegramBotBaseTest project - adding new simple AddStartCommand, AddHelpCommand and AddSettingsCommand to Program.cs to make it easier --- TelegramBotBaseTest/Program.cs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/TelegramBotBaseTest/Program.cs b/TelegramBotBaseTest/Program.cs index d052ae5..6371196 100644 --- a/TelegramBotBaseTest/Program.cs +++ b/TelegramBotBaseTest/Program.cs @@ -7,7 +7,7 @@ using Telegram.Bot.Types; using TelegramBotBase; using TelegramBotBase.Form; using TelegramBotBaseTest.Tests; - +using TelegramBotBase.Commands; namespace TelegramBotBaseTest { class Program @@ -17,7 +17,9 @@ namespace TelegramBotBaseTest BotBase bb = new BotBase(APIKey); - bb.BotCommands.Add(new BotCommand() { Command = "start", Description = "Starts the bot" }); + bb.BotCommands.AddStartCommand("Starts the bot"); + bb.BotCommands.AddHelpCommand("Should show you some help"); + bb.BotCommands.AddSettingsCommand("Should show you some settings"); bb.BotCommands.Add(new BotCommand() { Command = "form1", Description = "Opens test form 1" }); bb.BotCommands.Add(new BotCommand() { Command = "form2", Description = "Opens test form 2" }); bb.BotCommands.Add(new BotCommand() { Command = "params", Description = "Returns all send parameters as a message." });