%@ Language=VBScript %>
<%
Id = FormatTextHTML(request.QueryString("Id"))
DFlag = FormatTextHTML(request.QueryString("DFlag"))
sortBy = FormatTextHTML(request.QueryString("sortBy"))
Set rs = Server.CreateObject("ADODB.Recordset")
strSQL = "SELECT * FROM oa_WritingDinosaur WHERE ReportId = " & Id
'strSQL = "SELECT Q1, Q2, FirstName, LastInitial, Grade, WritingType FROM oa_WritingDinosaur WHERE ReportId = " & Id
'Response.Write strSQL
'Response.End
rs.CursorLocation = 3
rs.Open strSQL,"DSN=dotcom;UID=dotcom;password=well1234;",adOpenDynamic,3
if rs.EOF or rs.BOF then
blnEmptyRs = true
else
blnEmptyRs = false
end if
if DFlag = 1 then
displayGrade = rs("Grade")
if displayGrade = "0" then displayGrade = "K"
if displayGrade = "6" then displayGrade = "6+"
strBackTo = "Grade " & displayGrade
titleCol = "Grade"
strType = rs("Grade")
else
strBackTo = rs("WritingType")
titleCol = "Genre"
strType = Cstr(rs("WritingType"))
strType = replace(strType," ","%20")
end if
Title = rs("Q1")
Fname = rs("FirstName")
Initial = rs("LastInitial")
Story = rs("Q2")
GradeVal = rs("Grade")
if GradeVal = "0" then GradeVal = "K"
if rs("Grade") = "6" then GradeVal = "6+"
rs.Close
set rs = nothing
%>
Dinosaur Write
<%
doMenu
%>
<%
doFooter
%>