C#在应用程序中添加贝宝捐赠按钮 [英] c# add a PayPal donate button in application

查看:34
本文介绍了C#在应用程序中添加贝宝捐赠按钮的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想将PayPal Donate按钮添加到我的应用程序中,但是我不知道如何操作.我试图在Google和PayPal网站上进行搜索,但没有找到解决方案.你有什么建议吗 ?

I want to add PayPal Donate button to my application, but I don't know how. I tried to search in google and on PayPal site, but I didn't found a solution. Do you have any suggestions ?

推荐答案

我在该网站上找到了解决方案:

I found solution on that site : http://www.gorancic.com/blog/net/c-paypal-donate-button :

private void btnDonate_Click(object sender, System.EventArgs e)
{
    string url = "";

    string business     = "my@paypalemail.com";  // your paypal email
    string description  = "Donation";            // '%20' represents a space. remember HTML!
    string country      = "AU";                  // AU, US, etc.
    string currency     = "AUD";                 // AUD, USD, etc.

    url += "https://www.paypal.com/cgi-bin/webscr" +
        "?cmd=" + "_donations" +
        "&business=" + business +
        "&lc=" + country +
        "&item_name=" + description +
        "&currency_code=" + currency +
        "&bn=" + "PP%2dDonationsBF";

    System.Diagnostics.Process.Start(url);
}

这篇关于C#在应用程序中添加贝宝捐赠按钮的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆