Welcome Guest ( Login | Register )



All times are UTC - 7 hours [ DST ]



Post new topic Reply to topic  [ 8 posts ] 
Author Message
 Post subject: Tag description
PostPosted: Thu Jan 24, 2013 12:54 am 

Joined: Tue Nov 20, 2012 3:06 am
Posts: 22

Offline
Hello,

is there any possibility to show the tag description on the screen?
Thanks!


 Profile  
 
 Post subject: Re: Tag description
PostPosted: Thu Jan 24, 2013 3:48 am 
User avatar

Joined: Thu Nov 29, 2012 2:27 pm
Posts: 92

Offline
Hi Smolenak!

Yes you can, You access it via the Description property.

Create a textfield and try this.

Code:

void Screen1_Opened(System.Object sender, System.EventArgs e)
{
       Text1.Text = Globals.Tags.Tag1.Description;
}


The Description property is not visible in the script editor in iX but if you switch over to Visual Studio you will see it.

Best Regards

Edmund

_________________
Edmund Andersson

AITECH AB

Part of Beijer Integrator Group


 Profile  
 
 Post subject: Re: Tag description
PostPosted: Thu Jan 31, 2013 8:14 am 

Joined: Fri Jan 27, 2012 4:20 am
Posts: 166

Offline
As I understand, Visual C# must be installed ?
If yes, which version, release..?
regards, Waldemar


 Profile  
 
 Post subject: Re: Tag description
PostPosted: Thu Jan 31, 2013 8:54 am 

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

Offline
iX Developer has a C# compiler, and it installs it by default. You do not need to install Microsoft Visual Studio.

_________________
Best Regards,
Mark Monroe

Beijer Electronics, Inc. | Applications Engineer


 Profile  
 
 Post subject: Re: Tag description
PostPosted: Thu Jan 31, 2013 9:29 am 

Joined: Fri Jan 27, 2012 4:20 am
Posts: 166

Offline
Thank You Mark,
how can I make the "Description" option for a tag in the:
Text1.Text = Globals.Tags.Tag1.Description;
visible?


 Profile  
 
 Post subject: Re: Tag description
PostPosted: Thu Jan 31, 2013 9:33 am 

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

Offline
You code works to do what you want. Maybe you do not have a description for that tag.

Code:
      void Button1_Click(System.Object sender, System.EventArgs e)
      {
         Text1.Text = Globals.Tags.Tag1.Description;
      }

_________________
Best Regards,
Mark Monroe

Beijer Electronics, Inc. | Applications Engineer


 Profile  
 
 Post subject: Re: Tag description
PostPosted: Thu Jan 31, 2013 9:56 am 

Joined: Fri Jan 27, 2012 4:20 am
Posts: 166

Offline
I put some description to a tag.
But, when I put dot after the tag's name, no "Description" option is seen. Is it normal? Where all available options can be seen? May be, in Visual C# manual?


 Profile  
 
 Post subject: Re: Tag description
PostPosted: Thu Jan 31, 2013 10:11 am 

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

Offline
Only properties that are marked as "visible" can be seen. When you are in your script, you can press F1 and it will bring up the script help which has all of the properties and methods an object has.

Just because the autocomplete doesn't display a properties doesn't mean it is not there.

_________________
Best Regards,
Mark Monroe

Beijer Electronics, Inc. | Applications Engineer


 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 8 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: