Important Notice from AspDotNetStorefront
It is with dismay that we report that we have been forced, through the action of hackers, to shut off write-access to this forum. We are keen to leave the wealth of material available to you for research. We have opened a new forum from which our community of users can seek help, support and advice from us and from each other. To post a new question to our community, please visit: http://forums.vortx.com
Results 1 to 3 of 3

Thread: adding new fields to customers and cst_account

  1. #1
    press is offline Member
    Join Date
    May 2009
    Posts
    31

    Default adding new fields to customers and cst_account

    Hello,

    I have been able to add several fields to the customers.aspx.cs. But, when i use the same technique to add to the cst_account.cs it does not work.

    for example, adding the following results in error. I am figuring the MemberSince is not in the Target.Customer. But i cant figure out where to add it. The field is in the db.


    writer.Write(" <tr>");
    writer.Write(" <td width=\"25%\" align=\"right\" valign=\"middle\">Member Since:</td>");
    writer.Write(" <td width=\"75%\" align=\"left\" valign=\"middle\">");
    writer.Write(Localization.ToNativeDateTimeString(T argetCustomer.MemberSince));
    writer.Write(" </td>");
    writer.Write(" </tr>");

  2. #2
    press is offline Member
    Join Date
    May 2009
    Posts
    31

    Default re:adding new fields to customers and cst_account

    OK, i found that the targetcustomer is not included with source code, so any help looking up this data and placing it on the page would be greatly appreciated.

  3. #3
    press is offline Member
    Join Date
    May 2009
    Posts
    31

    Default re:adding new fields to customers and cst_account

    OK, i got a start on making this work. I found the DB.GetSqlS function, and the DB.GetSqlN function. So this is a start. So where is the DB.GetSqlD function to get dates, the "S" function does not seem to work with dates.

    I dont see why there is no documentation of this. But here is what i used.

    writer.Write(DB.GetSqlS("SELECT membershipid AS S FROM Customer where CustomerID=" + TargetCustomer.CustomerID.ToString()));

    Any help with the date fields would be awesome.