【问题标题】:c# add a PayPal donate button in applicationc# 在应用程序中添加一个 PayPal 捐赠按钮
【发布时间】:2013-08-26 10:38:36
【问题描述】:

我想在我的应用程序中添加 PayPal 捐赠按钮,但我不知道如何操作。我尝试在 google 和 PayPal 网站上搜索,但没有找到解决方案。你有什么建议吗 ?

【问题讨论】:

    标签: c# paypal


    【解决方案1】:

    检查thisthis 将帮助您实现。

    【讨论】:

      【解决方案2】:

      我在那个网站上找到了解决方案: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);
      }
      

      【讨论】:

      • 在哪里可以找到此 url 所需的值?我的意思是,我可以猜出我的国家字符串,但其他字符串呢?提前致谢
      • 仅供@BtcSources 和未来读者参考:如果你想要一个预设数量(例如...&lc=US&amount=1.99&currency_code=USD.....),看起来你也可以添加"&amount=" + amount
      【解决方案3】:

      你检查过他们的开发者 API 吗? https://developer.paypal.com/webapps/developer/docs/

      至少提到了 Android 和 IO。

      【讨论】:

        【解决方案4】:

        我假设您需要打开浏览器到定义的 Web 位置?并提供您的 PayPal 收款人参数?

        您是否在 Google 上搜索过 C#“打开浏览器窗口”或“打开浏览器 URL”?

        【讨论】:

          猜你喜欢
          • 1970-01-01
          • 2015-01-18
          • 1970-01-01
          • 1970-01-01
          • 2017-01-04
          • 1970-01-01
          • 2012-10-04
          • 2014-12-01
          • 2015-10-14
          相关资源
          最近更新 更多