Alpha Video Training
Results 1 to 3 of 3

Thread: Submit Button Problem

  1. #1
    Guest
    Real Name
    Gary Fletcher
    Join Date
    Apr 2000
    Posts
    162

    Default Submit Button Problem

    I have a dialog component that collects data. Once complete the user presses subit as the include Submit button has been check in properties. All that is supposed to happen is the data is entered into the database. This component is included in an a5w page.

    I have a separate a5w page that includes a totally different component to display data/detail. I also have another component on that same page that is a print pdf report, that works fine.

    PROBLEM: For some reason when I press the submit button on the dialog screen (a5w with dialog component) it's trying to find the PDF report and can't so I get an error.

    Why would one Submit componet be calling a different Submit component?

    Gary

  2. #2
    Volunteer Moderator Steve Workings's Avatar
    Real Name
    Steve Workings
    Join Date
    Apr 2000
    Location
    The Dreaded Chair
    Posts
    5,612

    Default Re: Submit Button Problem

    The answer is probably in your dialog component's AfterValidate event. How about posting the Xbasic in that event for us to see?
    -Steve


  3. #3
    Guest
    Real Name
    Gary Fletcher
    Join Date
    Apr 2000
    Posts
    162

    Default Re: Submit Button Problem

    Thanks. Here is the print/submit component button aftervalidate that is for creating the PDF in one of the a5w page. This is NOT the same page as the other page component below.

    dim filter as c
    dim order as c
    Filter = ".T."
    Order = ""
    Dim filename as c
    filename = session.session_folder + "tempreport.pdf"
    filename = report.saveas("MONTHLY REPORT@[PathAlias.ADB_Path]\service_report-v2.ddd","pdf",filter,order,filename,.f.)
    if file.exists(filename)
    currentform.RedirectTarget = session.session_url + "tempreport.pdf?" + time("hms3")
    end if

    ==================
    This is the aftervalidate code from a totally unrelated component:
    session.web_id = time("MMddyy0h0m0s3",now())

    tbl = table.open("<ADB_Path>\service_reporting-V2")
    tbl.enter_begin()
    tbl.web_id =session.web_id
    tbl.reportmonth =alltrim(reportmonth)
    tbl.First_name =alltrim(First_Name)
    tbl.Last_name =alltrim(Last_Name)
    tbl.Email =alltrim(Email)
    tbl.ReportDate =alltrim(ReportDate)
    tbl.Service_Hours=alltrim(Service_Hours)
    tbl.Commsvcmonth=alltrim(commsvcmth)
    tbl.SvcProj_Names=alltrim(Svcproj_Names)
    tbl.Meetings_Event_Hours=alltrim(Meetings_Event_Hours)
    tbl.Club_Events_Names=alltrim(Club_Events_Names)
    tbl.Clubhouse_Hours=alltrim(Clubhouse_Hours)

    tbl.enter_end(.t.)
    tbl.close()

Similar Threads

  1. Submit button
    By Dan Blank in forum Application Server Version 8
    Replies: 3
    Last Post: 05-17-2007, 04:31 AM
  2. Submit Button
    By johnm in forum Web Application Server v7
    Replies: 5
    Last Post: 04-09-2007, 08:13 AM
  3. Submit Button Location
    By Phil Rolf in forum Web Application Server v7
    Replies: 0
    Last Post: 07-09-2006, 09:09 AM
  4. lost the submit button
    By Duane Pederson in forum Web Application Server v6
    Replies: 1
    Last Post: 07-22-2005, 03:58 PM
  5. Submit Button Location
    By Phil Rolf in forum Web Application Server v6
    Replies: 4
    Last Post: 01-23-2005, 10:09 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •