cancel
Showing results for 
Search instead for 
Did you mean: 

Adjust the amount total in DPM C#

Environment: DPM, C#, VS 2010

 

I am baiscally creating a one page, 3 item shopping cart.  http://secure.avtec.edu (note: this is under development, so if the page doesnt render, it is temporary as I work on this issue).

 

I have looked at 3rd party shopping carts that claim to work with Auth.Net and are PCI compliant.  They are WAY overkill from what I need to do.  At the very least, a text field where the user can enter the final amount would be acceptable.

 

So I know I can edit this line on Index.aspx:

 <%using (Html.BeginSIMForm("http://secure.avtec.edu/home/sim", 1.99M, "6343LUe4Q9jf", "8S5mF7KP9ps8D2NJ", true)){ %>

 and I have found the reference to to 1.99M amount that generates the html on the FormBuilder.cs file and uses a hidden input field. I have tried various ways of trying to turn this into a text field or something flexible to be used. 

 

So if anyone has come up with a good solution to provide this functionality, I'd like to hear about it.

-OR-

If someone could verify that OOB functionality will ONLY provide for one static amount to be charged, I would (not) like to hear that as well.

 

Thanks.

SFink
Contributor
3 REPLIES 3

Download the sample app(NOT the sample code) on the SDKs download page. And see how it is used. Bascailly have to get the amount before going to the BeginSIMForm page.

RaynorC1emen7
Expert

Raynor,

I dont see sample code for DPM.  Although I do see that some users say it is like AIM.  Will this work, especially with MVC?

 

And yes, I have discovered the best way to do this is to pick up the extra line item and other info on a seperate page and pass it with cookies.  What a pain :smileysad:

 

I also find it amazing that when the reciept comes in the email, it shows the line items, and a total but does not tally the total for, as in there is a disconnect with the line items and the total at the server level.  Enough whining, I am glad you are here to elaborate. :smileyhappy:

Scroll down to the bottom on this http://developer.authorize.net/downloads/ for the MVC sample app. Or download the SIM sample code http://developer.authorize.net/downloads/samplecode/ and mod it to DPM, read the DPM documentation for required fields.

 

You need to pass in the total amount on the amount field. line items is for informational only.