Dim myCON As New SqlConnection(System.Web.Configuration.WebConfigurationManager.ConnectionStrings("dotSnapsDBConnectionString").ConnectionString)
myCommand.CommandText = "Select * from tblarticlettn where sectionissueid=@secID and LeadArticle='L'"
myCommand.Parameters.Add("@secID", SqlDbType.Int).Value = Request.QueryString("ID").ToString
myCON.Open()
myCommand.Connection = myCON
myDR = myCommand.ExecuteReader
If myDR.HasRows Then
myDR.Read()
lblFeature.Text = myDR("SectionTitle").ToString
lblArticleTitle.Text = myDR("Title").ToString
myrow = New TableRow
mycell = New TableCell
imgStory = New Image
imgStory.ImageUrl = myDR("ImageFileName").ToString
imgStory.ImageAlign = ImageAlign.Right
imgStory.Attributes.Add("hspace", 10)
imgStory.Attributes.Add("vspace", 2)
imgStory.Width = 150
mycell.Controls.Add(imgStory)
myrow.Cells.Add(mycell)
lblStory = New Label
Story = myDR("aText").ToString
posStart = InStr(Story.ToString, "<P>")
posEnd = InStr(Story.ToString, "</P>")
Story = Mid(Story, posStart, posEnd - 1)
lblStory.Text = Story
mycell.Controls.Add(lblStory)
tblStory.Rows.Add(myrow)
tblStory.Width = 465
End If