Solved

How to close an infopath form (in a browser) programatically from a button (NOT using RULES)

Posted on 2008-10-22
2
2,640 Views
Last Modified: 2012-05-05
Scenario: Infopath forms services, moss 2007, theres a button on the form , has some rules which are applied and then i want some code to run (including submit form) - all this works. But how do i get it to close afterwards? All i need is some C# to close form and make sure it returns to back to page form was opened from.

Thanks
0
Comment
Question by:davidsmythmeuk
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 28

Accepted Solution

by:
clayfox earned 500 total points
ID: 22776500
The default is to return to the originating page.

I believe Close() is what you want. Check the MSDN reference.

You could also put the close on the button as a rule, which will execute after the code.
0
 
LVL 1

Expert Comment

by:RHADMIN
ID: 33547472
No Close() method can't be referenced(not available) in FormCode.cs???  (NOT using RULES)
0

Featured Post

[Webinar] Code, Load, and Grow

Managing multiple websites, servers, applications, and security on a daily basis? Join us for a webinar on May 25th to learn how to simplify administration and management of virtual hosts for IT admins, create a secure environment, and deploy code more effectively and frequently.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Before you can digitally sign infopath forms, you must have a digital certificate. Microsoft Certificate Services will need to be enabled on a Windows Server 2008 to facilitate the creation and verification of the digital certifciates on the web ser…
Invest in your employees with these five simple steps to improve employee engagement and retention.
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…
Attackers love to prey on accounts that have privileges. Reducing privileged accounts and protecting privileged accounts therefore is paramount. Users, groups, and service accounts need to be protected to help protect the entire Active Directory …

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question