'' asp code Generated by Basic Processor
'' Original Page Name: C:\gmTestBed\FMStocks\src\FMSWeb\ASP\ViewProduct.asp

Imports System.Web
NameSpace FMSWeb
Public Partial class _ViewProduct : Inherits System.Web.UI.Page
   Public _t_head1 As FMSWeb._t_head
   Public _t_begin_cart1 As FMSWeb._t_begin_cart
   Public _t_end1 As FMSWeb._t_end
   Public _t_begin1 As FMSWeb._t_begin

   Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
      _t_head1 = New FMSWeb._t_head()
      _t_begin_cart1 = New FMSWeb._t_begin_cart()
      _t_end1 = New FMSWeb._t_end()
      _t_begin1 = New FMSWeb._t_begin()
      _t_begin_cart1.Include_Load(_t_head1, _t_begin1)
      _t_end1.Include_Load(_t_head1)
      _t_begin1.Include_Load(_t_head1)
   End Sub
   Dim prod As New FMSStore_Bus.Product
   Public m_sku As String = ""
   Public Sub EmitProduct()
      Dim rs As gmRTL.DataLib.SqlClient.Recordset = Nothing
      Dim sku As Integer = 0
      rs = prod.GetBySKU(CInt(m_sku))
      If (rs.EOF) Then
         HttpContext.Current.Response.Write("		No products found with SKU '" & m_sku & "'" & vbCrLf)
      Else
         HttpContext.Current.Response.Write("		<table border='0'>" & vbCrLf)
         HttpContext.Current.Response.Write("		<tr>" & vbCrLf)
         HttpContext.Current.Response.Write("			<td><b>" & HttpContext.Current.Server.HtmlEncode(Convert.ToString(rs.Fields("Description").Value)) & "</b>" & vbCrLf)
         HttpContext.Current.Response.Write("				" & Strings.FormatCurrency(rs.Fields("Price").Value,-1,TriState.UseDefault,TriState.UseDefault,TriState.UseDefault) & "" & vbCrLf)
         sku = gmRTL.Core.ConversionHelper.DBNullToValue(Of Integer)(rs.Fields("SKU").Value)
         rs = _t_begin_cart1.cart.GetByKey(CInt(_t_head1.g_AccountID),sku)
         If (rs.EOF) Then
            HttpContext.Current.Response.Write("					<a title='Add this item to your cart'" & vbCrLf)
            HttpContext.Current.Response.Write(" href='" & "cart.aspx?Add=" & sku & "'>Add to cart</a>" & vbCrLf)
         Else
            HttpContext.Current.Response.Write("					<tr><td>You have " & rs.Fields("Quantity").Value & " of this item" & vbCrLf)
            HttpContext.Current.Response.Write("					in your <a href='cart.aspx'>shopping cart</a>, <a title='Add this item to your cart'" & vbCrLf)
            HttpContext.Current.Response.Write(" href='" & "cart.aspx?Add=" & sku & "'>Add to cart</a> anyway?" & vbCrLf)
         End If
         HttpContext.Current.Response.Write("		<tr>" & vbCrLf)
         HttpContext.Current.Response.Write("			<td><br>Finding the next Microsoft has been the Holy Grail for many investors. However," & vbCrLf)
         HttpContext.Current.Response.Write("				anyone who has dabbled in technology stocks can't help but be dismayed at their" & vbCrLf)
         HttpContext.Current.Response.Write("				extreme volatility--it's not unusual for tech stocks to gain or lose 10 to 20" & vbCrLf)
         HttpContext.Current.Response.Write("				percent in a single day. So how can you win in this market and find the next" & vbCrLf)
         HttpContext.Current.Response.Write("				Cisco, Intel, or Oracle? The key to winning, says bestselling author Geoffrey" & vbCrLf)
         HttpContext.Current.Response.Write("				Moore, is to play the 'gorilla game.'" & vbCrLf)
         HttpContext.Current.Response.Write("				<p>Moore's previous two books, <i>Crossing the Chasm</i> and <i>Inside the" & vbCrLf)
         HttpContext.Current.Response.Write("				Tornado</i>, are the bibles for many marketing professionals and product" & vbCrLf)
         HttpContext.Current.Response.Write("				managers. In these books, Moore describes the life cycle common to the" & vbCrLf)
         HttpContext.Current.Response.Write("				successful adoption of technology products and pinpoints moments in the cycle," & vbCrLf)
         HttpContext.Current.Response.Write("				for example 'the chasm,' the 'bowling alley,' and the 'tornado,' where products" & vbCrLf)
         HttpContext.Current.Response.Write("				can either flourish or fade away. In <i>The Gorilla Game</i>, Moore takes these" & vbCrLf)
         HttpContext.Current.Response.Write("				concepts, with the help of coauthors Paul Johnson and Tom Kippola, applies them" & vbCrLf)
         HttpContext.Current.Response.Write("				to finding gorilla stocks--stocks that dominate their market niche. The book" & vbCrLf)
         HttpContext.Current.Response.Write("				looks at how the market values technology stocks and provides case studies of" & vbCrLf)
         HttpContext.Current.Response.Write("				markets where gorillas have been born. Moore and his coauthors put their ideas" & vbCrLf)
         HttpContext.Current.Response.Write("				to the test in the final chapter and pick a portfolio of stocks that they" & vbCrLf)
         HttpContext.Current.Response.Write("				believe have the potential to become winners in the gorilla game. The result is" & vbCrLf)
         HttpContext.Current.Response.Write("				a highly perceptive investment guide that anyone who's a fan of Moore's earlier" & vbCrLf)
         HttpContext.Current.Response.Write("				work will find exciting and profitable. Highly recommended.</p>" & vbCrLf)
         HttpContext.Current.Response.Write("		</table>" & vbCrLf)
      End If
   End Sub
End Class
End Namespace
