I use CSharpTradeOffers ( GitHub ) library

It has functions

SendTradeOfferWithLink (CSharpTradeOffers / Trading / EconServiceHandler.cs) and SendOfferResponse (CSharpTradeOffers / Trading / Data Classes / SendOfferResponse.cs)

I have the following code:

 TradeOffer offer = new TradeOffer(); offer.Me.Assets.Add(csgoInventory.Items.First().Value.Items.First().ToCEconAsset(730)); var response = offerHandler.SendTradeOfferWithLink(steamid, token, msg, "1", offer, _account.AuthContainer); Console.WriteLine(response.Error); 

SendTradeOfferWithLink returns a SendOfferResponse with Error and JsonProperty("strError")

I need to output to the console if, when I try to send an exchange, some kind of error occurs (for example, such ). But for some reason, response.Error returns null, and if the exchange did not go because of a similar error, nothing is output to the console.

Explain, please, how can I display this Error?

  • one
    Maybe it makes sense to ask the library developers? Your library is rather exotic, I don’t think that many of the participants used it. - VladD
  • Well, maybe someone just has enough general programming knowledge to tell where the error is)) - Danny
  • I think the question is not in general knowledge, but in how the library returns errors. That is, this is the internal detail of the kitchen of this very library. - VladD
  • So that's why I indicated the link to the githab and the location of EconServiceHandler.cs and SendOfferResponse - Danny
  • You offer us to understand someone else's code? Prosherstit entire project, it's so easy to find the part that is responsible for the error, to understand what is wrong in it, and write the answer? You ask quite a lot. And what did you do? Have you already started researching the githaba code? Tell us about what you have to date. - VladD

0