CyberStore Session Variables

CyberStore uses ASP.NET session variables to retain shopper and navigation context while a session is active. The following names and meanings are preserved from the CyberStore 2023 technical reference.

Treat CyberStore session variables as read-only. CyberStore sets these values as part of its business logic; changing them can cause unexpected behavior.

Session variable Description
Customer_ID Customer identifier associated with the currently signed-in account.
LastCategory_ID Category identifier for the category page most recently visited by the shopper.
userID Account identifier for the currently signed-in account. The value is null for an anonymous shopper.
userName Concatenated first and last name of the signed-in user.
userCompany Company name of the Customer associated with the signed-in account.
userCustomerNumber SYSPRO Customer Number associated with the Customer linked to the signed-in account.

Check whether a shopper is signed in

The legacy example uses userID to distinguish an anonymous shopper from a signed-in shopper.

<%
if (Session["userID"] == null)
{
%>
You are not currently signed in.
<%
}
else
{
%>
You are signed in as <b><%= Session["userName"].ToString() %></b>.
<%
}
%>

This site uses Just the Docs, a documentation theme for Jekyll.