Click here to Skip to main content
15,900,110 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi all,

Please explain this,

var cmd = new TsoapCommand('newContractForNewCustomer');


see the code:
C#
if(newCustomer)
                {
                    var cmd = new TsoapCommand('newContractForNewCustomer');
                    cmd.addParam('customerName',document.getElementById('txtname').value);
                    cmd.addParam('street',document.getElementById('txtstreet').value);
                    cmd.addParam('postalCode',document.getElementById('txtPostCode').value);
                    cmd.addParam('city',document.getElementById('txtCity').value);
                    cmd.addParam('country',document.getElementById('txtCountry').value);
                    cmd.addParam('mobilePhone',document.getElementById('txtmobilePhone').value);
                    cmd.addParam('IDNumber',document.getElementById('txtIDNumber').value);
                    cmd.addParam('email', document.getElementById('txtEmail').value);


                    cmd.addParam('emailinvoice', document.getElementById('txtEmailInvoice').value);
                    if (document.getElementById('chksendInvoiceYes').checked)
                        sendInvocie = "Yes";
                    else if (document.getElementById('chksendInvoiceNo').checked)
                        sendInvocie = "No";
                    cmd.addParam('sendinvoice', sendInvocie);
                    //--------------------------------------------------------

                    cmd.addParam('ccCardType',strcctype);
                    cmd.addParam('ccNumber',document.getElementById('txtCCNumber').value);
                    cmd.addParam('ccExpireDate',expiredateFull);
                    cmd.addParam('ccHolderName',document.getElementById('txtCCHolderName').value);
                    cmd.addParam('ccHolderSSN',document.getElementById('txtCCHolderSSN').value);
                    cmd.addParam('contractDate',document.getElementById('textboxforcondate').value);
                    cmd.addParam('noticeDate',document.getElementById('textboxfornoticedate').value);
                    cmd.addParam('terminationDate',document.getElementById('textboxforterminationdate').value);
                    cmd.addParam('ActterminationDate',document.getElementById('textboxforActterminationdate').value);
                    cmd.addParam('unitID',strUnitId);
                    cmd.addParam('unitNumber',strunitnumber);
                    cmd.addParam('unitPrice',document.getElementById('textboxforunitprice').value);
                    cmd.addParam('monthlyRent',"");
                    cmd.addParam('TenantRight',document.getElementById('txtTenantRight').innerText);

                    cmd.addParam('customerComments',document.getElementById('txtCustComment').innerText);
                    cmd.addParam('custDiscountAmount',document.getElementById('txtfordiscountamnt').value);
                    cmd.addParam('netPayment',document.getElementById('txtfornetprice').value);
                    cmd.addParam('signatureDate',document.getElementById('txtsignature').value);
                    cmd.addParam('bindingUntilDate',document.getElementById('txtbindingdate').value);
                    cmd.addParam('vacancyDate', document.getElementById('txtvacancydate').value);
                    cmd.addParam('EvictionNoticedate', document.getElementById('txtEvictionNoticedate').value);
                    cmd.addParam('EvictionNumber', document.getElementById('txtEvictionNumber').value);
                    cmd.addParam('EstEviction', document.getElementById('txtEstEviction').value);
                    cmd.addParam('ActEviction', document.getElementById('txtActEviction').value);
                    cmd.addParam('Communication', document.getElementById('txtCommunication').innerText);
                    cmd.addParam('userName', userName);
                    var strPayType = document.getElementById('ddPaymentType1').selectedIndex;

                    cmd.addParam('PaymentType', document.getElementById('ddPaymentType1').options[strPayType].value);
                    result = cmd.send('SbWebService.asmx');
                }






Thanks in advance.
Posted
Updated 18-Aug-13 20:52pm
v2
Comments
Ron Beyer 19-Aug-13 0:59am    
I can't find any reference to a TsoapCommand, is it something that is in the software that you are using? If so, how can we explain it?

1 solution

var cmd = new TsoapCommand('newContractForNewCustomer');


As you probably know, the above line creates an instance of the TsoapCommand (passing the string newContractForNewCustomer to its constructor).
Like Ron Beyer already pointed out, the TsoapCommand class is probably provided by a library you are using. You should check out the library documentation or its source code (if available) for fully understanding it.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900