This method creates only the table with the fieldlist inside of it, it does not generate the HTML Form and submit button - you can wrap those around with Response writes as follows:
o.EditRecord(lnDisplayMode,lcObjectName)
lcObjectName
Optional - The name of the object or cursor that is used for ASP style tag when lnDisplayMode = 2. The default is the name of the ALIAS() selected.
* wwDemo::EditRecord
Function EditRecord
lcAction = Request.QueryString("Action")
lcCustNo = PADL(ALLTRIM(Request.QueryString("CustNo")),8)
IF !USED("tt_cust")
USE TT_CUST IN 0
ENDIF
SELE TT_CUST
IF EMPTY(lcCustNo)
THIS.ErrorMsg("No Customer Number to edit",;
"Please enter a customer ID to edit")
RETURN
ENDIF
LOCATE FOR CUSTNO = lcCustNo
IF !FOUND()
THIS.ErrorMsg("No Customer Number to edit","Please enter a customer ID to edit")
RETURN
ENDIF
pcMessage = ""
Response.HTMLHeader("Customer Editing")
*** We're now on our record to edit or save
DO CASE
CASE lcAction = "Save"
*** Save the data from the Request object
loSC = CREATE("wwShowCursor")
loSC.SaveRecord()
pcMessage="Record Saved"
ENDCASE
Response.Write([<form action="wc.dll?wwDemo~EditRecord~&Custno=] + ALLTRIM(lcCustNo) + [&Action=Save" method="POST">] +CRLF)
Response.Write([<input type="submit" name="btnSubmit" value="Save"><p>])
*** Always display the data
loSC = CREATE("wwShowCursor")
loSC.cExtraTableTags = [style="font:normal normal 10pt Arial"]
loSC.EditRecord()
Response.Write( loSC.GetOutput() )
Response.Write([</form>] + CRLF)
Response.HTMLFooter
RETURN