Save behavior - InfoPath Dev
in

InfoPath Dev

Save behavior

Last post 11-01-2006 08:50 AM by Patrick Halstead. 8 replies.
Page 1 of 1 (9 items)
Sort Posts: Previous Next
  • 10-25-2006 07:08 AM

    Save behavior

    Good day all,

    I would like for my infopath form to send an email using a data connection when the form gets saved.

    So when a user is finished saving the document, I would like the form to automatically send an email to a data connection i have set.

    Is there a way to do this.

    Appreciate everyones's help on this!!!

    Thanks!
    Bernie
  • 10-25-2006 09:18 AM In reply to

    You can call emailadapter.Submit method in the OnSaveRequest() event.
  • 10-25-2006 10:12 AM In reply to

    quote:
    Originally posted by Agni Jonnalagadda

    You can call emailadapter.Submit method in the OnSaveRequest() event.




    OK, I am quite the newbie at this, so would you care to go into a little more detail, cause I have no clue what you are talking about?

    Thanks!!!!!
  • 10-26-2006 04:39 AM In reply to

    Hi Nikhoi,

    Regarding the EmailAdapter, u can find the code in the following link in both JScript and C#.

    http://www.infopathdev.com/forums/topic.asp?TOPIC_ID=2583&SearchTerms=email,adapter

    Also search the InfoPathdev forums with EmailAdapter as the keyword. You will see lot of posts.

    Now u need to place the code in the OnSaveRequest() event, so that this code executes every time u save the form.

    Go to Tools menu-->Form Options
    Select the "Open and Save" tab in the Form Options dialog
    Check the "Save using Custom code" check box
    Click Edit button
    U will get the OnSaveRequest method in the Visual Studio (or Microsoft Script Editor) based on what u use.

    Regards,
    Abhishek
  • 10-27-2006 05:26 AM In reply to

    quote:
    Originally posted by Abhishek

    Hi Nikhoi,

    Regarding the EmailAdapter, u can find the code in the following link in both JScript and C#.

    http://www.infopathdev.com/forums/topic.asp?TOPIC_ID=2583&SearchTerms=email,adapter

    Also search the InfoPathdev forums with EmailAdapter as the keyword. You will see lot of posts.

    Now u need to place the code in the OnSaveRequest() event, so that this code executes every time u save the form.

    Go to Tools menu-->Form Options
    Select the "Open and Save" tab in the Form Options dialog
    Check the "Save using Custom code" check box
    Click Edit button
    U will get the OnSaveRequest method in the Visual Studio (or Microsoft Script Editor) based on what u use.

    Regards,
    Abhishek



    OK, I am really sorry, but that link was no help at all!!! It said to leave stuff blank, but it would not let me procede. When I would copy and paste the code into the script editor, it would look nothing like when I copied it. You have to remember, I have never programmed before, so clueless would probably be an understatement. I was hoping it would just be a copy and paste and change some variables, but it doesn't seem that simple. I don't understand why Microsoft could just made save behavior like open behavior. I am sooo lost... please help!!!
  • 10-31-2006 05:02 AM In reply to

    So... is anyone going to help me with this?
  • 10-31-2006 08:16 AM In reply to

    Hi Bernie,

    Sorry about the delay, but we are here to help you with InfoPath issues, not to help you understand how to do programming. We are busy and we have jobs and this is a free forum. We don't make any money on it. It is provided as a service to the developer community. We assume you already learned how to code, or that you are not going to code. Unfortunately, your request to e-mail on save requires code. Now, if you use SharePoint submit (which is a form of save), you can e-mail on submit and you don't need to write any code. You can also hook up a button to e-mail the form, without any code (and save the form as an attachment in your OutLook Sent Items). Those are two options I would recommend for non-programmers.

    If you found a bug in our code, we will be more than happy to help fix it. However, it looks like you just don't know how to get it to compile, etc. We can't teach you how to code - that's a long journey and it would not be fair to others in the forum (since we would end up spending too much time trying to help the helpless).

    If you want to become a developer, I recommend reading my book "Developing Solutions with InfoPath" and working through all of the examples. Then, I would read the InfoPath SDK completely (boring but very helpful). When you have done these two things, you will be able to do simple coding in InfoPath, but you won't be a programmer yet.

    My advice: figure out how to do what you want without writing code.
    Patrick Halstead
    Project Manager at Qdabra
  • 11-01-2006 05:46 AM In reply to

    quote:
    Originally posted by Patrick Halstead

    Hi Bernie,

    Sorry about the delay, but we are here to help you with InfoPath issues, not to help you understand how to do programming. We are busy and we have jobs and this is a free forum. We don't make any money on it. It is provided as a service to the developer community. We assume you already learned how to code, or that you are not going to code. Unfortunately, your request to e-mail on save requires code. Now, if you use SharePoint submit (which is a form of save), you can e-mail on submit and you don't need to write any code. You can also hook up a button to e-mail the form, without any code (and save the form as an attachment in your OutLook Sent Items). Those are two options I would recommend for non-programmers.

    If you found a bug in our code, we will be more than happy to help fix it. However, it looks like you just don't know how to get it to compile, etc. We can't teach you how to code - that's a long journey and it would not be fair to others in the forum (since we would end up spending too much time trying to help the helpless).

    If you want to become a developer, I recommend reading my book "Developing Solutions with InfoPath" and working through all of the examples. Then, I would read the InfoPath SDK completely (boring but very helpful). When you have done these two things, you will be able to do simple coding in InfoPath, but you won't be a programmer yet.

    My advice: figure out how to do what you want without writing code.




    Thanks I guess... didn't want to learn to code. Don't have the time to learn because oh yess... I also have job!!! The responses above make it sound simple, that's why I continued with this, and this isn't the first topic that nobody had responded to.

    Nice shameless plug on your book ;-)
  • 11-01-2006 08:50 AM In reply to

    Hi again,
    What about the two codeless suggestions of using SharePoint submit and a rule or using just e-mail?
    Patrick Halstead
    Project Manager at Qdabra
Page 1 of 1 (9 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.