Crash opening a saved form - InfoPath Dev
in

InfoPath Dev

Crash opening a saved form

Last post 10-11-2006 03:56 AM by LaurieAPMarsh. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 10-06-2006 08:56 AM

    Crash opening a saved form

    I have followed the instructions in the "Add Custom Buttons to the Repeating Table and Section Widget" Tutorial - except that I am using C# managed code behind the form.

    I then create a new form with some data in it and save it to a file.

    When I open that saved form using the File Open command in InfoPath, InfoPath crashes with the "Microsoft Office InfoPath has encountered a problem and needs to close. We are sorry for the inconvenience." error.

    I have narrowed it down to the mere existance of the OnClick event handler for my added button. Below is my event handler. When it is included in the solution, InfoPath crashes. If I delete this method and only this method, it doesn't crash.

    [InfoPathEventHandler(MatchPath = "widgetMoveToAccomplished", EventType = InfoPathEventType.OnClick)]
    public void widgetMoveToAccomplished_OnClick(DocActionEvent e)
    {
    try
    {
    thisXDocument.UI.Alert("got here");
    }
    catch (Exception err)
    {
    thisXDocument.UI.Alert("Error occured: " + err.Message);
    }
    } // End of widgetMoveToAccomplished_OnClick.




    Another piece of interesting information is that if I double-click on the saved form to open it (instead of using the File Open command), InfoPath will open the form without crashing and yes, my added button in the repeating table menu works just fine.

    Anyone go any ideas how to work around this crash (other than telling the users not to use the File Open menu command)??
  • 10-08-2006 11:14 PM In reply to

    Re: Crash opening a saved form

    Hi Laurie,
    I've asked Matt to respond to this. More soon!~
    Patrick Halstead
    Project Manager at Qdabra
  • 10-09-2006 08:54 AM In reply to

    Re: Crash opening a saved form

    Hey Laurie,

    It seems that you are running into the incredibly weird, annoying, and downright perplexing bug that Thierry and I have also run into. Our discussion is outlined here:http://www.infopathdev.com/forums/topic.asp?TOPIC_ID=2311 . However, it seems like you found a slight workaround by double-clicking instead of using File->Open.

    Let me ask you this: Are you able to open two of the same forms at the same time? This is when I was seeing the crash, and let me tell you it makes development incredibly annoying.

    Sorry to disappoint you, but I don't think there is anything you can do except switch to IP2007 as I've heard this bug is fixed there. I haven't tried it personally, but that's what I've heard.

    Good luck and let us know if you figure anything out!
    Matt Faus / Microsoft InfoPath MVP
    Qdabra® Software / Streamline data gathering to turn process into knowledge
  • 10-11-2006 03:56 AM In reply to

    Re: Crash opening a saved form

    Thanks for the info Matt.

    Yes, I can successfully open >1 form by double-clicking on the form file. I only get the crash using the Open command within InfoPath.

    If I make any additional progress, I will post it here.
Page 1 of 1 (4 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.