我有这个代码在C#
和我试图添加url按钮能够添加一个网页url,但我不知道如何添加它,这是我的代码:
this.handlers = default(DiscordRpc.EventHandlers);
DiscordRpc.Initialize("xxx", ref this.handlers, true, null);
this.handlers = default(DiscordRpc.EventHandlers);
DiscordRpc.Initialize("xxx", ref this.handlers, true, null);
this.presence.details = "Barcelona";
this.presence.state = "Barcelona";
this.presence.startTimestamp = (long)(DateTime.UtcNow - new DateTime(1970, 1, 1, 0, 0, 0)).TotalSeconds;
this.presence.largeImageKey = "https://media.tenor.com/Y_bfmgZ2sZ0AAAAM/aubameyang-fc-barcelona.gif";
this.presence.smallImageKey = "https://media.tenor.com/Y_bfmgZ2sZ0AAAAM/aubameyang-fc-barcelona.gif";
this.presence.largeImageText = "HI";
this.presence.smallImageText = "FCB";
DiscordRpc.UpdatePresence(ref this.presence);
这就是我想补充的。
1条答案
按热度按时间aoyhnmkz1#
只需创建
System.Windows.Forms.Button
类的示例并将其添加到formsControls
集合中,如下所示