Ask our Experts
Didn't find what you are looking for? Ask our experts!
Launch of Consumer/Home Owner registration process! We are pleased to announce the commencement of the Consumer/Home Owner Registration Process on Community. Consumers/Home Owners may now proceed to register by clicking on Login/Register. The process is straightforward and designed to be completed in just a few steps.
Support forum for Machine and Motion Control solutions, including Lexium MC12 and robotics, PacDrive, Modicon PLCs and I/Os, EcoStruxure Machine Expert Twin, … - from design, implementation to troubleshooting and more, by Schneider Electric
Search in
Link copied. Please paste this link to share this article on your social media post.
Posted: 2024-04-23 10:29 PM . Last Modified: 2024-11-21 12:53 AM
This feature requires the WebVisu object (VISU_TASK) and the library TextListUtils to execute the relevant functions.
The example code shown below, needs to be executed in a low priority task with long cycle time (e.g. prio 25 and 500ms cycle time) to avoid performance issues.
Depending on the selected variable values udiLanguage, sID and sTextList the selected text list content will be returned by the function LTU.ReturnValues.
PROGRAM Get_Text_from_Textlist
VAR
udiLanguage :UDINT :=1;
sID :STRING :='1';
sTextList :STRING :='TextList1';
wsResult :WSTRING;
retVal :TLU.ReturnValues;
END_VAR
CASE udiLanguage OF
0: //Default - English
CmpDynamicText.DynamicTextChangeLanguage(stLanguage := 'Default');
1: //German
CmpDynamicText.DynamicTextChangeLanguage(stLanguage := 'de');
2: //French
CmpDynamicText.DynamicTextChangeLanguage(stLanguage := 'fr');
END_CASE:
retVal:=TLU.GetTextW(pwsText := ADR(wsResult), diSize := SIZEOF(wsResult), sTextList := sTextList, sTextIndex:=sID);
Link copied. Please paste this link to share this article on your social media post.
You’ve reached the end of your document
Create your free account or log in to subscribe to the board - and gain access to more than 10,000+ support articles along with insights from experts and peers.