My version is 15.0.3.
I got a problem when trying to use 'CContact.BillSingleNonDuesSubscription(...)'.
The routine is as the following:
If a client want to register as a professional member, he/she inputs basic information in the first page, then click 'submit'. System creates a new user, then automatically log in and redirect to the payment page.
In this payment page, I was trying to define a new CSubscription and call BillSingleNonDuesSubscription function which require two parameters -- productCode and effectiveDate. My code to call this function is like this:
CSubscription subscription = contact.NewSubscription(pname, true);
subscription.BilledDate = DateTime.Now;
subscription.Balance = cprod.MemberUnitPrice;
subscription.AmountPaid = subscription.Balance;
subscription.BeginDate = subscription.BilledDate;
subscription.PaidThruDate = subscription.BilledDate.AddYear(1);
contact.BillSingleNonDuesSubscription(subscription.ProductCode, subscription.BeginDate);
Response.Write(subscription.PaidThruDate.ToString() + " " + subscription.EffectiveDate.ToString());
First it complains that 'effective date must be later than paidthrudate', then i change the effective date to PaidThruDate.AddDays(1), and got same error message, the message is gone when i set the effective date to PaidThruDate.AddDays(366), which is 1 year after paid through date. I am confused about the meaning of PaidThruDate, EffectiveDate and the relationship between them.
I also did another test, I logged out and login again from the default system login page, then directly go to the payment page. This time the code is passed successfully (I use BeginDate in that bill function), but the subscription.EffectiveDate output is something like '01-01-0001 12:00:00AM'. I wonder whether there is something wrong with my automatic login code or not.
Hope someone can help me. Thanks.
iBO.Net version
Are you using the version of iBO.Net from 15.0.3 or have you downloaded any of the ETP versions? If you've downloaded an ETP version, you might try getting the most recent one; I seem to recall this may have been fixed.
If you don't have the ETP version, you might request access to it; the 15.0.3 version is missing a lot of updates that have been included in the ETP download.