Sponsored Content
Full Discussion: Vs basic
The Lounge What is on Your Mind? Vs basic Post 302998076 by cb88 on Wednesday 24th of May 2017 09:50:58 PM
Old 05-24-2017
We use Indusoft VBScript at work... its basically the code behind script in all the HMIs we produce.

It could be better, but there isn't much you can't do in it that you need to do. It does a few things like bit level addressing, and you can work around limitations in the HMI package by being able to address global HMI variables by string formatting thier names and passing to a function which allows you to pretend that you have nested classes.. even though it doesn't really support that.

For instance Say I have a Control panel class CP as and I want to have Estop values in it... with fault, description and id fields, the work around is that I generate the tag names as strings to referece them in a for loop.... which you would be able to directly do with nested classes, its a much needed organizational structure that is sadly missing.

CP.ESTOP_Desc_1 ... n
CP.ESTOP_ID_1 ... n
CP.ESTOP_Fault_1 ... n

Interestingly they are intending to transition to Javascript... I'm not sure if that is a good thing or a bad thing :/ At least the HMIs will run on Linux potentially going forward currently they are ball and chained to Windows.
 

8 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Basic

hi, I am pretty new both to unix and this forum, can anyone help me to give shortcuts to my commands... eg:- instead of "cd /usr/bin" i want to to give " bin " and get to that path. I'm using HP-UX 11.0 abey (2 Replies)
Discussion started by: abey
2 Replies

2. What is on Your Mind?

Basic...

hi, I am pretty new both to unix and this forum, can anyone help me to give shortcuts to my commands... eg:- instead of "cd /usr/bin" i want to to give " bin " and get to that path. I'm using HP-UX 11.0 abey (2 Replies)
Discussion started by: abey
2 Replies

3. HP-UX

Bt-basic

Hi Guys, I very new to bt-basic even I got 8 years experience on UNIX. I searched through google about bt-basic but nothing really give me solid documentation. Anybody have documentation or manual for this bt-basic? Pls help me (2 Replies)
Discussion started by: shahru
2 Replies

4. UNIX for Dummies Questions & Answers

Need some basic help

Hi everyone, I need some help! I know that this is a very simple little problem but I seem to be stuck. I was just wondering if you could show me the right way. I basicly have to write a single line of commands (using piping) to do the following: From the file data.txt, select all of the... (2 Replies)
Discussion started by: itk
2 Replies

5. HP-UX

to know the basic

Hi, Good morning I want to install HP-Unix in my PC. I already have windows XP home edition in my PC. I do not want remove XP,But I need HP-Unix in the same system. Is it posssible? If it is what is the name and version of HP-Unix cd? Where can I get the CD to install. I have... (4 Replies)
Discussion started by: nandhini
4 Replies

6. UNIX for Dummies Questions & Answers

basic if else

I know this is pretty basic, but i cant figure it out to save my life. i want it to ask for a variable, as long as that variable isnt -/0 i want it to print out the area. else if the variable is -/0, i want it to print out invalid entry. the only problem is it will still try to print out the... (1 Reply)
Discussion started by: cookiebooy
1 Replies

7. Solaris

Basic - how do I?

How do I use ls and grep together to count a certain number of files in a directory? -Thanks (1 Reply)
Discussion started by: secno
1 Replies

8. UNIX for Dummies Questions & Answers

Basic help

Hi , I need to know the difference between $((command)) and $(command) and $(($(command))). "" and '' and ``. I have tried searching the help files but cant able to find this. Could you let me knoq about any document. Thanks (4 Replies)
Discussion started by: Raj999
4 Replies
class_initialize()														class_initialize()

Name
  class_initialize - Object class method for one-time class initialization.

Synopsis
  typedef void (*XtProc)(void);

Description
  The  class_initialize()  method is registered on the class_initialize field of the Object, RectObj, or Core class structures, and is called
  exactly once by the Intrinsics before any instances of the class are created.

  The class_initialize() method takes no arguments and returns no value.  It performs initialization that should be done once for this	class
  and  all its subclasses, such as registering type converters and interning atoms and quarks.	Compare this with the class_part_initialize()
  method which is called once for its class and also for every subclass, and is responsible for initializing fields in the class part  struc-
  ture.

  The  class_initialize()  method  is  not  chained and cannot be inherited.  If a widget class does not need any one-time initialization, it
  should specify NULL in its class_initialize field.

  The fact that this method is not chained means that when a given widget class, C, is initialized, only the  class_initialize()  method  for
  that	class  is  called--the methods for the superclasses B and A are not called during the initialization of C.  If the class_initialize()
  method were chained, then the method for widget class A would be invoked whenever a subclass, such as B or C, were initialized.  Since  the
  method  is  intended for one-time global initializations, this would be inappropriate.  Although this method is not chained, the Intrinsics
  ensure that the superclasses of a class will be initialized before the class itself.	So,  in  fact,	the  class_initialize()  methods  for
  classes A and B are guaranteed to have been called before the class_initialize() method for C is called.

  See the "Background" section below for more information on when this method is called.

Usage
  The  class_initialize()  performs  one-time, global initializations for the class.  It should not initialize the fields of the class struc-
  ture--that is the job of the class_part_initialize() method, which is a chained method, and is invoked for class and all of its subclasses.
  class_initialize()  and class_part_initialize() perform initialization of the widget class.  It is the initialize() method that initializes
  the instance structure of the widget--it is invoked whenever a widget instance is created.

Example
  The following procedure is the class_initialize() method of the Xaw Form widget.  Note that  it  registers  two  resource  converters,  and
  interns quarks (in global variables) for use by the String-to-EdgeType converter.

     static void ClassInitialize()
     {
	 static XtConvertArgRec parentCvtArgs[] = {
	     {XtBaseOffset, (XtPointer)XtOffsetOf(WidgetRec, core.parent),
		  sizeof(Widget)}
	 };
	 XawInitializeWidgetSet();
	 XtQChainLeft	= XrmPermStringToQuark("chainleft");
	 XtQChainRight	= XrmPermStringToQuark("chainright");
	 XtQChainTop	= XrmPermStringToQuark("chaintop");
	 XtQChainBottom = XrmPermStringToQuark("chainbottom");
	 XtQRubber	= XrmPermStringToQuark("rubber");

	 XtAddConverter( XtRString, XtREdgeType, _CvtStringToEdgeType, NULL, 0 );
	 XtSetTypeConverter (XtRString, XtRWidget, XmuNewCvtStringToWidget,
			     parentCvtArgs, XtNumber(parentCvtArgs), XtCacheNone,
			     NULL);
     }

Background
  All widget classes, whether they have a class_initialize() method or not, must start with their class_inited field False.

  The  first  time  a  widget  of a class is created, XtCreateWidget() ensures that the widget class and all superclasses are initialized, in
  superclass-to-subclass order, by checking each class_inited field.  If this field is False, XtCreateWidget() calls  the  class_initialize()
  and  the  class_part_initialize()  methods  for  the	class  and all its superclasses.  The Intrinsics then set the class_inited field to a
  nonzero value.  After the one-time initialization, a class structure is constant.   This  initialization  process  can  also	be  performed
  explicitly, without creating a widget, by calling XtInitializeWidgetClass().

See Also
  XtInitializeWidgetClass(1),
  Core(3),
  class_part_initialize(4), initialize(4).

Xt - Intrinsics Methods 													class_initialize()
All times are GMT -4. The time now is 01:11 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy