How to enable selecting new e-mails when Outlook add-in is open?





.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ height:90px;width:728px;box-sizing:border-box;
}







-1















I'm creating an add-in for Outlook (Desktop Version, not Online) using Visual Studio 2017. The main intent for the application is to extract attachments and upload to specified SAP records. This could typically be notifications, PurchaseOrders etc.



The add-in works by opening a form where you can select from options like zipping the files, delete files from e-mail, upload the e-mail it self etc.



My challenge is that the add-in works for the e-mails selected when you open the add-in. But to select new e-mails you'll need to close the form, select new e-mails and then re-open/run the add-in. Basically the add-in form is acting as a dialog box and the Outlook explorer window is in-active. Is there a setting or any thing that will allow me to select new e-mails when the form/dialog box is open or is this somethinig I'll have to live with?



Thanks for your support.
BR
Fnk










share|improve this question


















  • 1





    Don't open the form modally??

    – Eric Legault
    Jan 3 at 21:57











  • Or create a task pane in Outlook Explorer.

    – Dmitry Streblechenko
    Jan 4 at 22:33











  • Hi Eric. It may be opened modally. Why is kind of what I'm looking for and how to change that. The load form call is the standard:

    – Fnk
    Jan 22 at 15:39











  • Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load <br/> Thanks

    – Fnk
    Jan 22 at 15:46


















-1















I'm creating an add-in for Outlook (Desktop Version, not Online) using Visual Studio 2017. The main intent for the application is to extract attachments and upload to specified SAP records. This could typically be notifications, PurchaseOrders etc.



The add-in works by opening a form where you can select from options like zipping the files, delete files from e-mail, upload the e-mail it self etc.



My challenge is that the add-in works for the e-mails selected when you open the add-in. But to select new e-mails you'll need to close the form, select new e-mails and then re-open/run the add-in. Basically the add-in form is acting as a dialog box and the Outlook explorer window is in-active. Is there a setting or any thing that will allow me to select new e-mails when the form/dialog box is open or is this somethinig I'll have to live with?



Thanks for your support.
BR
Fnk










share|improve this question


















  • 1





    Don't open the form modally??

    – Eric Legault
    Jan 3 at 21:57











  • Or create a task pane in Outlook Explorer.

    – Dmitry Streblechenko
    Jan 4 at 22:33











  • Hi Eric. It may be opened modally. Why is kind of what I'm looking for and how to change that. The load form call is the standard:

    – Fnk
    Jan 22 at 15:39











  • Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load <br/> Thanks

    – Fnk
    Jan 22 at 15:46














-1












-1








-1








I'm creating an add-in for Outlook (Desktop Version, not Online) using Visual Studio 2017. The main intent for the application is to extract attachments and upload to specified SAP records. This could typically be notifications, PurchaseOrders etc.



The add-in works by opening a form where you can select from options like zipping the files, delete files from e-mail, upload the e-mail it self etc.



My challenge is that the add-in works for the e-mails selected when you open the add-in. But to select new e-mails you'll need to close the form, select new e-mails and then re-open/run the add-in. Basically the add-in form is acting as a dialog box and the Outlook explorer window is in-active. Is there a setting or any thing that will allow me to select new e-mails when the form/dialog box is open or is this somethinig I'll have to live with?



Thanks for your support.
BR
Fnk










share|improve this question














I'm creating an add-in for Outlook (Desktop Version, not Online) using Visual Studio 2017. The main intent for the application is to extract attachments and upload to specified SAP records. This could typically be notifications, PurchaseOrders etc.



The add-in works by opening a form where you can select from options like zipping the files, delete files from e-mail, upload the e-mail it self etc.



My challenge is that the add-in works for the e-mails selected when you open the add-in. But to select new e-mails you'll need to close the form, select new e-mails and then re-open/run the add-in. Basically the add-in form is acting as a dialog box and the Outlook explorer window is in-active. Is there a setting or any thing that will allow me to select new e-mails when the form/dialog box is open or is this somethinig I'll have to live with?



Thanks for your support.
BR
Fnk







vb.net outlook-addin






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Jan 3 at 9:29









FnkFnk

13




13








  • 1





    Don't open the form modally??

    – Eric Legault
    Jan 3 at 21:57











  • Or create a task pane in Outlook Explorer.

    – Dmitry Streblechenko
    Jan 4 at 22:33











  • Hi Eric. It may be opened modally. Why is kind of what I'm looking for and how to change that. The load form call is the standard:

    – Fnk
    Jan 22 at 15:39











  • Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load <br/> Thanks

    – Fnk
    Jan 22 at 15:46














  • 1





    Don't open the form modally??

    – Eric Legault
    Jan 3 at 21:57











  • Or create a task pane in Outlook Explorer.

    – Dmitry Streblechenko
    Jan 4 at 22:33











  • Hi Eric. It may be opened modally. Why is kind of what I'm looking for and how to change that. The load form call is the standard:

    – Fnk
    Jan 22 at 15:39











  • Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load <br/> Thanks

    – Fnk
    Jan 22 at 15:46








1




1





Don't open the form modally??

– Eric Legault
Jan 3 at 21:57





Don't open the form modally??

– Eric Legault
Jan 3 at 21:57













Or create a task pane in Outlook Explorer.

– Dmitry Streblechenko
Jan 4 at 22:33





Or create a task pane in Outlook Explorer.

– Dmitry Streblechenko
Jan 4 at 22:33













Hi Eric. It may be opened modally. Why is kind of what I'm looking for and how to change that. The load form call is the standard:

– Fnk
Jan 22 at 15:39





Hi Eric. It may be opened modally. Why is kind of what I'm looking for and how to change that. The load form call is the standard:

– Fnk
Jan 22 at 15:39













Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load <br/> Thanks

– Fnk
Jan 22 at 15:46





Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load <br/> Thanks

– Fnk
Jan 22 at 15:46












1 Answer
1






active

oldest

votes


















0














Figured it out in the end. Found the answer in one of my books: "Sams Teach Yourself: Visual Basics 2015". (Apparently in 24 hours if you can plough through 600 pages in that time).



Anyway, I was looking in the Load Form and not the Show Form code. Somehow I'd used frm.ShowDialog() rather than frm.Show(). Apparently the ShowDialog() method opens the form as Modal while Show() opens as non-Modal.



As a result the code for the Ribbon button now is as follows:
Imports Microsoft.Office.Tools.Ribbon



Public Class Ribbon1

Private Sub Ribbon1_Load(ByVal sender As System.Object, _
ByVal e As RibbonUIEventArgs) Handles MyBase.Load

End Sub

Private Sub Button1_Click(sender As Object, e As RibbonControlEventArgs) _
Handles Button1.Click

Dim frm As MainForm 'Define a form object

frm = New MainForm()
'frm.ShowDialog() 'Method opens form object as Modal
frm.Show() 'Method opens form object as non-Modal
End Sub
End Class


I hope this may help someone else on the same experience level as myself.






share|improve this answer


























    Your Answer






    StackExchange.ifUsing("editor", function () {
    StackExchange.using("externalEditor", function () {
    StackExchange.using("snippets", function () {
    StackExchange.snippets.init();
    });
    });
    }, "code-snippets");

    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "1"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });














    draft saved

    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f54019480%2fhow-to-enable-selecting-new-e-mails-when-outlook-add-in-is-open%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    0














    Figured it out in the end. Found the answer in one of my books: "Sams Teach Yourself: Visual Basics 2015". (Apparently in 24 hours if you can plough through 600 pages in that time).



    Anyway, I was looking in the Load Form and not the Show Form code. Somehow I'd used frm.ShowDialog() rather than frm.Show(). Apparently the ShowDialog() method opens the form as Modal while Show() opens as non-Modal.



    As a result the code for the Ribbon button now is as follows:
    Imports Microsoft.Office.Tools.Ribbon



    Public Class Ribbon1

    Private Sub Ribbon1_Load(ByVal sender As System.Object, _
    ByVal e As RibbonUIEventArgs) Handles MyBase.Load

    End Sub

    Private Sub Button1_Click(sender As Object, e As RibbonControlEventArgs) _
    Handles Button1.Click

    Dim frm As MainForm 'Define a form object

    frm = New MainForm()
    'frm.ShowDialog() 'Method opens form object as Modal
    frm.Show() 'Method opens form object as non-Modal
    End Sub
    End Class


    I hope this may help someone else on the same experience level as myself.






    share|improve this answer






























      0














      Figured it out in the end. Found the answer in one of my books: "Sams Teach Yourself: Visual Basics 2015". (Apparently in 24 hours if you can plough through 600 pages in that time).



      Anyway, I was looking in the Load Form and not the Show Form code. Somehow I'd used frm.ShowDialog() rather than frm.Show(). Apparently the ShowDialog() method opens the form as Modal while Show() opens as non-Modal.



      As a result the code for the Ribbon button now is as follows:
      Imports Microsoft.Office.Tools.Ribbon



      Public Class Ribbon1

      Private Sub Ribbon1_Load(ByVal sender As System.Object, _
      ByVal e As RibbonUIEventArgs) Handles MyBase.Load

      End Sub

      Private Sub Button1_Click(sender As Object, e As RibbonControlEventArgs) _
      Handles Button1.Click

      Dim frm As MainForm 'Define a form object

      frm = New MainForm()
      'frm.ShowDialog() 'Method opens form object as Modal
      frm.Show() 'Method opens form object as non-Modal
      End Sub
      End Class


      I hope this may help someone else on the same experience level as myself.






      share|improve this answer




























        0












        0








        0







        Figured it out in the end. Found the answer in one of my books: "Sams Teach Yourself: Visual Basics 2015". (Apparently in 24 hours if you can plough through 600 pages in that time).



        Anyway, I was looking in the Load Form and not the Show Form code. Somehow I'd used frm.ShowDialog() rather than frm.Show(). Apparently the ShowDialog() method opens the form as Modal while Show() opens as non-Modal.



        As a result the code for the Ribbon button now is as follows:
        Imports Microsoft.Office.Tools.Ribbon



        Public Class Ribbon1

        Private Sub Ribbon1_Load(ByVal sender As System.Object, _
        ByVal e As RibbonUIEventArgs) Handles MyBase.Load

        End Sub

        Private Sub Button1_Click(sender As Object, e As RibbonControlEventArgs) _
        Handles Button1.Click

        Dim frm As MainForm 'Define a form object

        frm = New MainForm()
        'frm.ShowDialog() 'Method opens form object as Modal
        frm.Show() 'Method opens form object as non-Modal
        End Sub
        End Class


        I hope this may help someone else on the same experience level as myself.






        share|improve this answer















        Figured it out in the end. Found the answer in one of my books: "Sams Teach Yourself: Visual Basics 2015". (Apparently in 24 hours if you can plough through 600 pages in that time).



        Anyway, I was looking in the Load Form and not the Show Form code. Somehow I'd used frm.ShowDialog() rather than frm.Show(). Apparently the ShowDialog() method opens the form as Modal while Show() opens as non-Modal.



        As a result the code for the Ribbon button now is as follows:
        Imports Microsoft.Office.Tools.Ribbon



        Public Class Ribbon1

        Private Sub Ribbon1_Load(ByVal sender As System.Object, _
        ByVal e As RibbonUIEventArgs) Handles MyBase.Load

        End Sub

        Private Sub Button1_Click(sender As Object, e As RibbonControlEventArgs) _
        Handles Button1.Click

        Dim frm As MainForm 'Define a form object

        frm = New MainForm()
        'frm.ShowDialog() 'Method opens form object as Modal
        frm.Show() 'Method opens form object as non-Modal
        End Sub
        End Class


        I hope this may help someone else on the same experience level as myself.







        share|improve this answer














        share|improve this answer



        share|improve this answer








        edited Feb 7 at 9:20









        Rai

        1,1444823




        1,1444823










        answered Feb 7 at 8:02









        FnkFnk

        13




        13
































            draft saved

            draft discarded




















































            Thanks for contributing an answer to Stack Overflow!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f54019480%2fhow-to-enable-selecting-new-e-mails-when-outlook-add-in-is-open%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            MongoDB - Not Authorized To Execute Command

            How to fix TextFormField cause rebuild widget in Flutter

            in spring boot 2.1 many test slices are not allowed anymore due to multiple @BootstrapWith