PureEngage On-Premises

 View Only

Sign Up

  • 1.  Is it possible to programmatically maximize IWS window, or re-size regions?

    Posted 11-05-2014 00:45
    Hello,

    My question is in regards to customizing IWS with C#.

    In the past while customizing IWS I found found the occasional need to maximize an interaction window within code.  When I have needed to do this, I have always had a custom control (derived from UserControl) that is placed in a view.  I would typically attach a method to fire after the control is loaded:

    this.Loaded += new RoutedEventHandler(MainView_Loaded);

    In my MainView_Loaded method:

    Window parentWindow = Window.GetWindow(this);
    parentWindow.WindowState = WindowState.Maximized;

    This has worked nicely for me in the past.

    However I am wondering how I might be able to maximize an interaction window in a scenario that I am not placing a custom control on this screen.  Is this possible?  I have thought of placing a dummy hidden control, which is a solution, it just seems like a strange one.  I am not sure how to obtain a reference to the actual interaction window, or something that is derived from a Dependency Object.

    My second question is, is it possible to programmatically re-size regions?  I am interested in re-sizing InteractionWorksheetRegion when an interaction loads.  Haven't seen anything in the API yet about this.

    Regards,
    Andrew


  • 2.  RE: Is it possible to programmatically maximize IWS window, or re-size regions?

    Posted 11-20-2014 17:55
    It sounds like you normally have a custom button on the Interactions Window, and when that button loads they fire off some code to Maximize.

    Now the problem is that you don’t have any custom controls to leverage and therefore, you don’t know when to trigger your Maximize code.

    You could use a Custom Command to detect when the Interactions Window is shown and then within that custom command, fire off some Maximize code.  You don’t have to use this particular command.  There are plenty of others that might better meet your requirements.

    This is the Command:
    ShowInteractionsWindow
    -CommandParameter; IInteractionsWindow
    - Interaction: IInteraction
    - Case: ICase
    (Others can be found here:  http://docs.genesys.com/Documentation/IW/8.1.4/Developer/ReferenceforCommands )
     

    Here are instructions on how to use custom commands:
    http://docs.genesys.com/Documentation/IW/8.1.4/Developer/UseCustomizableCommands


  • 3.  RE: Is it possible to programmatically maximize IWS window, or re-size regions?

    Posted 01-08-2015 19:47
    Hi Troy,

    Sorry there has been such a delay in me responding.

    I have thought of and attempted using Custom Commands to do this in the past.  My challenge has been - how do I get a reference to the actual Window object in this scenario?

    The IInteractionsWindow inherits from IView.  I forget offhand, but I do not believe IView inherits from System.Windows.DependencyObject, so I can't do:
     
    Window parentWindow = Window.GetWindow(myIInteractionWindowObject);

    My other question was - do you know if / how regions can be resized programatically?


  • 4.  RE: Is it possible to programmatically maximize IWS window, or re-size regions?

    Posted 08-24-2017 18:04
    For reference, one of the latest WDE plugin examples contains a reference on how to do this.