Code not working upon submitting the form - InfoPath Dev
in

InfoPath Dev

Use our Google Custom Search for best site search results.

Code not working upon submitting the form

Last post 11-03-2011 08:33 PM by akosila. 5 replies.
Page 1 of 1 (6 items)
Sort Posts: Previous Next
  • 10-27-2011 06:37 PM

    Code not working upon submitting the form

    I have an infopath 2010 web enabled form. I created a data connection that submits data to a sharepoint library.

    then in the Submit Options, i chose, "Perform custom action using Code" and edited the code.

    In the code, i am calling a method to check if the value entered in the form is valid (custom validation)

    I submit the form in CA.

    when Im going to test it and i clicked the "Submit" button, the form doest close and the code doesnt work.

  • 11-01-2011 07:52 AM In reply to

    Re: Code not working upon submitting the form

    Does it work in InfoPath Filler?

    Hilary Stoupa

  • 11-02-2011 05:37 PM In reply to

    Re: Code not working upon submitting the form

    sorry but i have not tried the infopath filler. because I  right click > design my form.xsn, its opening in Infopath designer.

  • 11-02-2011 09:28 PM In reply to

    Re: Code not working upon submitting the form

    When I am submitting the form, i got this javascript error. and i was not redirected to my form library


    Webpage error details

    User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; InfoPath.3; .NET4.0C; .NET4.0E)
    Timestamp: Thu, 3 Nov 2011 05:22:16 UTC


    Message: 'null' is null or not an object
    Line: 2
    Char: 296672
    Code: 0
    URI: http://site/_layouts/inc/Core.js?rev=8PdoqL6fQahtzwwVSZ2lpw%3D%3D

  • 11-03-2011 07:47 AM In reply to

    Re: Code not working upon submitting the form

    I should have been more clear - does your code work when you preview your form from designer? If not, you can run in debug to figure out what is wrong.

    EDIT: Also, you can post your code if you'd like - someone may be able to see what it going wrong.

    Hilary Stoupa

  • 11-03-2011 08:33 PM In reply to

    Re: Code not working upon submitting the form

    I got the code working by upgrading it. now my problem is

     Form does not close/redirect user to form library after i click my custom button "Submit"

    in my submit button there is a code that checks/validates the values in my textboxes. but when I click submit, the form is submitted to the form library however the form doesnt close.

    the values of the infopath form is removed (blank textboxes) and when I click my custom "Submit" button, i encounter a javascript error in my browser ("null" is null in core.js)

     

Page 1 of 1 (6 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.