Welcome Guest ( Login | Register )



All times are UTC - 7 hours [ DST ]



Post new topic Reply to topic  [ 6 posts ] 
Author Message
 Post subject: create popup
PostPosted: Tue Aug 23, 2011 11:42 pm 

Joined: Tue Aug 23, 2011 10:05 pm
Posts: 3

Offline
hi

i new to the ix developer, i need to clarify some doubts about in popup, for other hmi we create only one popup for one type of device for example if we have 5 manual DOL motor we create only one popup for 5 device and we pass the different tag to different motors at the runtime, for the same how to do here, Please anyone help me

regards
s jeyaseelan


 Profile  
 
 Post subject: Re: create popup
PostPosted: Wed Aug 24, 2011 9:33 am 
User avatar

Joined: Fri Jul 15, 2011 3:21 pm
Posts: 214

Offline
The only way I know to do this is using internal tags (tags without an address) and script. The script would go in the "Opened" and "Closed" events to copy the values between tags. The code would look like this:

Code:
public partial class PopupScreen
    {
      
      void PopupScreen_Opened(System.Object sender, System.EventArgs e)
      {
         if (Globals.Tags.ScreenIDTag.Value == 0) {
            Globals.Tags.InternalTag1.Value = Globals.Tags.Tag1.Value;
            Globals.Tags.InternalTag2.Value = Globals.Tags.Tag2.Value;
         }
         else if (Globals.Tags.ScreenIDTag.Value == 1) {
            Globals.Tags.InternalTag1.Value = Globals.Tags.Tag3.Value;
            Globals.Tags.InternalTag2.Value = Globals.Tags.Tag4.Value;
         }
      }
      
      void PopupScreen_Closed(System.Object sender, System.EventArgs e)
      {
         if (Globals.Tags.ScreenIDTag.Value == 0) {
            Globals.Tags.Tag1.Value = Globals.Tags.InternalTag1.Value;
            Globals.Tags.Tag2.Value = Globals.Tags.InternalTag2.Value;
         }
         else if (Globals.Tags.ScreenIDTag.Value == 1) {
             Globals.Tags.Tag3.Value = Globals.Tags.InternalTag1.Value;
             Globals.Tags.Tag4.Value = Globals.Tags.InternalTag2.Value;
         }         
      }
    }


Attachment:
tag_list.JPG
tag_list.JPG [ 36.51 KiB | Viewed 4869 times ]


Attachment:
copy_tags_ex.JPG
copy_tags_ex.JPG [ 82.74 KiB | Viewed 4869 times ]


In the button "Click" action for the button to open the popup screen you'll need to set the "ScreenIDTag".

Attachment:
button_click_action.JPG
button_click_action.JPG [ 39.51 KiB | Viewed 4869 times ]

_________________
Best Regards,

Beijer Electronics, Inc.
Ron Lloyd | Applications Engineer


 Profile  
 
 Post subject: Re: create popup
PostPosted: Wed Aug 24, 2011 11:31 pm 

Joined: Tue Aug 23, 2011 10:05 pm
Posts: 3

Offline
Hi Ron L

thank for your reply

i get some idea and i write the script in popup screen open condition, because that the real tags values not updated at time of popup open, when i close and open the popup then only i get the real tags values

i need continuous update when popup screen open

please help me how to do that/


 Profile  
 
 Post subject: Re: create popup
PostPosted: Thu Aug 25, 2011 9:20 am 
User avatar

Joined: Fri Jul 15, 2011 3:21 pm
Posts: 214

Offline
That is possible, with more scripting, but if this starts to get too complex, you might be better off just making lots of popup screens.

First you need to change the Tags with addresses to "Always Active".

Attachment:
always_active.JPG
always_active.JPG [ 61.42 KiB | Viewed 4861 times ]


Then you would have to go to the "Script" section under tags and insert some code to the "ValueChanged" actions to update the internal tags.

Attachment:
tags_valuechange.JPG
tags_valuechange.JPG [ 115.94 KiB | Viewed 4861 times ]

_________________
Best Regards,

Beijer Electronics, Inc.
Ron Lloyd | Applications Engineer


 Profile  
 
 Post subject: Re: create popup
PostPosted: Mon Aug 29, 2011 3:55 am 

Joined: Tue Aug 23, 2011 10:05 pm
Posts: 3

Offline
hi ron l

again thanks for your replay, but i can't execute this Script for two popups because this script written in value changed when 1 st motor tags value change d the popup displayed the 1st motor value again when i click the 2nd motor button that time also the popup displayed the same value of 1st motor popup value,because the values are stored in the internal tags at the time of value changed, the popup displayed only last stored values for all motor popup

again sorry for disturbance please guide me

again thanks for your support


 Profile  
 
 Post subject: Re: create popup
PostPosted: Mon Aug 29, 2011 9:14 am 
User avatar

Joined: Fri Jul 15, 2011 3:21 pm
Posts: 214

Offline
I don't understand what you're asking. You're welcome to send me a copy of your project if you would like me to take a look.

_________________
Best Regards,

Beijer Electronics, Inc.
Ron Lloyd | Applications Engineer


 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 6 posts ] 

All times are UTC - 7 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron