<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Trouble Understanding ASP.NET objects in Integration and Testing</title>
    <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/Trouble-Understanding-ASP-NET-objects/m-p/27198#M14396</link>
    <description>&lt;P&gt;I just recently started using Authorize.Net to submit our website's payments. &amp;nbsp;I am implementing this through the Advanced Integration Method using ASP.Net.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So, I have the SDK downloaded and am able to submit some sample transactions via my dev account ... but it seems that some of the Authorize.net objects are half-baked ... or I'm just not aware of how to correctly use them (hoping for some enlightenment from you guys)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For example ... to create a request object, the sample shows this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;Dim request As New AuthorizationRequest("4007000000027", "1214", 10.0, "Test Transaction #1")&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Which is fine, but why doesn't this work?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;Dim request As New AuthorizeNet.AuthorizationRequest() &amp;nbsp; &amp;nbsp;*** THIS LINE OF CODE IS INVALID&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; request.CardNum = "4007000000027"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; request.CardCode = "123"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; request.ExpDate = "1214"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; request.Amount = 10.0&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; request.Description = "test transaction #1234"&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;request.Type = "AUTH_ONLY"&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It doesn't work, because you can't instantiate without any variables. &amp;nbsp;So, I'm very confused as to why the object lets me interact via its properties, but forces me to create it with parameter values I could "load" later. &amp;nbsp;This seem very odd to me.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Next question ... Customer information ....&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;the sample shows me doing it this way:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;request.AddCustomer("john123", "John", "Smith", "123 Main St", "CA", "90201")&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Instead of using the objects it has built in ... like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;Dim cust As New AuthorizeNet.Customer&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; cust.Email = "johnsmith@gmail.com"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; cust.ID = "john123"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; Dim address As New AuthorizeNet.Address&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; address.ID = "john123"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; address.First = "John"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; address.Last = "Smith"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; address.Street = "123 Main St."&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; address.City = "Beverly Hills"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; address.State = "CA"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; address.Zip = "90201"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; address.Phone = "212.555.1000"&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;cust.BillingAddress = address &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;SPAN&gt;*** THIS LINE OF CODE IS INVALID&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;&lt;SPAN&gt;and this one too:&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;cust.BillingAddress.Add(address) &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; *** THIS LINE OF CODE IS INVALID&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Am I missing something? &amp;nbsp;Is there any use for some of the objects (like customer or address) ... Or should I just be using all these listed fields like&amp;nbsp;x_amount, x_exp_date, etc? &amp;nbsp;These don't seem to be right when doing this in OOProgramming.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;LAST QUESTION:&lt;/P&gt;&lt;P&gt;What field is the Response Reason Code in? &amp;nbsp;I found the Response Code:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;Dim response As AuthorizeNet.GatewayResponse = gate.Send(request)&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;Dim respcode = &amp;nbsp;response.ResponseCode&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance,&lt;BR /&gt;Nate&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 14 Jun 2012 21:45:56 GMT</pubDate>
    <dc:creator>Jibboo73</dc:creator>
    <dc:date>2012-06-14T21:45:56Z</dc:date>
    <item>
      <title>Trouble Understanding ASP.NET objects</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/Trouble-Understanding-ASP-NET-objects/m-p/27198#M14396</link>
      <description>&lt;P&gt;I just recently started using Authorize.Net to submit our website's payments. &amp;nbsp;I am implementing this through the Advanced Integration Method using ASP.Net.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So, I have the SDK downloaded and am able to submit some sample transactions via my dev account ... but it seems that some of the Authorize.net objects are half-baked ... or I'm just not aware of how to correctly use them (hoping for some enlightenment from you guys)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For example ... to create a request object, the sample shows this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;Dim request As New AuthorizationRequest("4007000000027", "1214", 10.0, "Test Transaction #1")&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Which is fine, but why doesn't this work?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;Dim request As New AuthorizeNet.AuthorizationRequest() &amp;nbsp; &amp;nbsp;*** THIS LINE OF CODE IS INVALID&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; request.CardNum = "4007000000027"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; request.CardCode = "123"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; request.ExpDate = "1214"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; request.Amount = 10.0&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; request.Description = "test transaction #1234"&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;request.Type = "AUTH_ONLY"&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It doesn't work, because you can't instantiate without any variables. &amp;nbsp;So, I'm very confused as to why the object lets me interact via its properties, but forces me to create it with parameter values I could "load" later. &amp;nbsp;This seem very odd to me.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Next question ... Customer information ....&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;the sample shows me doing it this way:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;request.AddCustomer("john123", "John", "Smith", "123 Main St", "CA", "90201")&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Instead of using the objects it has built in ... like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;Dim cust As New AuthorizeNet.Customer&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; cust.Email = "johnsmith@gmail.com"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; cust.ID = "john123"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; Dim address As New AuthorizeNet.Address&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; address.ID = "john123"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; address.First = "John"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; address.Last = "Smith"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; address.Street = "123 Main St."&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; address.City = "Beverly Hills"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; address.State = "CA"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; address.Zip = "90201"&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt; address.Phone = "212.555.1000"&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;cust.BillingAddress = address &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;SPAN&gt;*** THIS LINE OF CODE IS INVALID&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;&lt;SPAN&gt;and this one too:&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;cust.BillingAddress.Add(address) &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; *** THIS LINE OF CODE IS INVALID&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Am I missing something? &amp;nbsp;Is there any use for some of the objects (like customer or address) ... Or should I just be using all these listed fields like&amp;nbsp;x_amount, x_exp_date, etc? &amp;nbsp;These don't seem to be right when doing this in OOProgramming.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;LAST QUESTION:&lt;/P&gt;&lt;P&gt;What field is the Response Reason Code in? &amp;nbsp;I found the Response Code:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;Dim response As AuthorizeNet.GatewayResponse = gate.Send(request)&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000FF" face="courier new,courier"&gt;Dim respcode = &amp;nbsp;response.ResponseCode&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance,&lt;BR /&gt;Nate&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Jun 2012 21:45:56 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/Trouble-Understanding-ASP-NET-objects/m-p/27198#M14396</guid>
      <dc:creator>Jibboo73</dc:creator>
      <dc:date>2012-06-14T21:45:56Z</dc:date>
    </item>
    <item>
      <title>Re: Trouble Understanding ASP.NET objects</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/Trouble-Understanding-ASP-NET-objects/m-p/27204#M14399</link>
      <description>&lt;P&gt;My advice is to download the source code and modify it to fit you.&lt;/P&gt;</description>
      <pubDate>Thu, 14 Jun 2012 23:26:52 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/Trouble-Understanding-ASP-NET-objects/m-p/27204#M14399</guid>
      <dc:creator>RaynorC1emen7</dc:creator>
      <dc:date>2012-06-14T23:26:52Z</dc:date>
    </item>
  </channel>
</rss>

