You are not registered yet. Please click here to register!


 
 
plc storereviewsdownloads
This board is for PLC Related Q&A ONLY. Please DON'T use it for advertising, etc.
 
Try our online PLC Simulator- FREE.  Click here now to try it.

---------->>>>>Get FREE PLC Programming Tips

New Here? Please read this important info!!!


Go Back   PLCS.net - Interactive Q & A > PLCS.net - Interactive Q & A > LIVE PLC Questions And Answers

PLC training tools sale

Reply
 
Thread Tools Display Modes
Old November 15th, 2018, 07:22 PM   #1
TheWaterboy
Lifetime Supporting Member + Moderator
United States

TheWaterboy is offline
 
TheWaterboy's Avatar
 
Join Date: May 2006
Location: State of Denial
Posts: 820
Concat 2 strings into a tagname?

Can I take 2 strings, concatenate them and use that result as a TagName of a Bool or any other element?

I'm creating an AOI for MSG stats and it would be ideal if I could use only the MSG tagname and create the .EN and .DN tagnames within the AOI on the fly.

Seemed possible till I started a few minutes ago but I cant figure our how to assign a bools Tagname to a concatenated string. I might be on the wrong track.

I know the MSG has to be created separately and be controller scoped so I'm only trying to reference an already existing bit.
  Reply With Quote
Old November 15th, 2018, 09:06 PM   #2
OkiePC
Lifetime Supporting Member
United States

OkiePC is offline
 
OkiePC's Avatar
 
Join Date: Mar 2005
Location: ENE of Nowhere Oklahoma
Posts: 9,983
I don't know of any way to make a tagname dynamic within the PAC.
__________________
It's not all the variables I am most concerned with, it's the undiscovered constants.
  Reply With Quote
Old November 15th, 2018, 09:11 PM   #3
Mispeld
Member
United States

Mispeld is offline
 
Mispeld's Avatar
 
Join Date: Feb 2017
Location: VA
Posts: 391
This post was discussed in a recent thread, and could be a method to achieve the desired outcome.

http://www.plctalk.net/qanda/showthread.php?t=105602
__________________
"The greatest enemy of knowledge is not ignorance, it is the illusion of knowledge." -Stephen Hawking
  Reply With Quote
Old November 16th, 2018, 12:12 AM   #4
Ken Roach
Lifetime Supporting Member + Moderator
United States

Ken Roach is offline
 
Ken Roach's Avatar
 
Join Date: Apr 2002
Location: Seattle, WA
Posts: 14,292
Please don't.

Please don't.

Please don't.

Don't try to package MSG instructions into an AOI in a system that principally does telemetry.

Don't try to do something obscure and almost-impossible with tag name references instead of arrays.

If you think you need to create a new feature or invent a function that the system doesn't do, step back and look at the problem more carefully. Brute-force logic is very frequently the most easy to write, troubleshoot, and maintain over time.

Last edited by Ken Roach; November 16th, 2018 at 12:14 AM.
  Reply With Quote
Reply
Jump to Live PLC Question and Answer Forum

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Topics
Thread Thread Starter Forum Replies Last Post
Red Lion Crimson 3, Concat 3 strings to make a new one. Edmhydraulics LIVE PLC Questions And Answers 6 April 30th, 2016 03:15 PM
RSLogix 5000 CONCAT instruction question blmccallum LIVE PLC Questions And Answers 3 March 30th, 2012 03:55 AM
Strings WinCC -> S7-400 Jeebs LIVE PLC Questions And Answers 2 June 4th, 2010 10:43 AM
Siemens S7 Strings cjd1965 LIVE PLC Questions And Answers 4 May 11th, 2010 05:23 PM
S7 Strings <CR><LF> pethoek LIVE PLC Questions And Answers 2 April 17th, 2009 03:25 AM


All times are GMT -5. The time now is 06:35 AM.


.