Moving a popup window

A forum devoted to the discussion of all topics having to do with scripting and other advanced programming using iX Developer.
Post Reply
fsturlese
Posts: 36
Joined: Tue Nov 22, 2011 11:57 am

Moving a popup window

Post by fsturlese »

Hello,
is there any way to dynamically change the position of a popup window by scripting in iX for PC?

Thanks,
Federico.

mark.monroe
Posts: 824
Joined: Tue Mar 13, 2012 9:53 am

Re: Moving a popup window

Post by mark.monroe »

Here is code that you can use to move a popup window. In this case there are buttons on a popup screen that can be used to move the window.

Code: Select all

namespace Neo.ApplicationFramework.Generated
{
    using System.Windows.Forms;
    using System;
    using System.Drawing;
    using Neo.ApplicationFramework.Tools;
    using Neo.ApplicationFramework.Common.Graphics.Logic;
    using Neo.ApplicationFramework.Controls;
    using Neo.ApplicationFramework.Interfaces;
    
    //Screen2 is a popup window
    public partial class Screen2
    {
		
		//On button click move popup left
		void btLeft_Click(System.Object sender, System.EventArgs e)
		{
			this.Left -= 50;
		}
		
		//On button click move popup right
		void btRight_Click(System.Object sender, System.EventArgs e)
		{
			this.Left += 50;
		}
		
		//On button click move popup up
		void btUp_Click(System.Object sender, System.EventArgs e)
		{
			this.Top -= 50;
		}
		
		//On button click move popup down
		void btDown_Click(System.Object sender, System.EventArgs e)
		{
			this.Top += 50;
		}
    }
}
Best Regards,
Mark Monroe

Beijer Electronics, Inc. | Applications Engineer

Post Reply