Sponsored Content
Top Forums Shell Programming and Scripting Echo var1,var2,var3,var4,var5,var6 in loop help Post 302137476 by blowtorch on Tuesday 25th of September 2007 08:40:17 AM
Old 09-25-2007
I did quite a bit of digging, and got this:

eval echo \$mask${count2}

Try it. If it works, let me know.
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Nested Loop to Echo Multiple Arrays

I have three arrays which hold three elements each. I have a fourth array which contains the names of those three arrays. I'm having difficulty creating a nested loop that can loop through each array and echo their values. script #!/bin/ksh # array of locations (usa, london, australia)... (1 Reply)
Discussion started by: yongho
1 Replies

2. UNIX for Dummies Questions & Answers

*fixed if (( var1 && var2 )) ??

*EDIT -- **FIXEd I must've done something wrong, because it works now.. I punched in "if" in the forum search but nothing came up, so I'm posting it here. Quick question: Can someone correct my syntax. #!/bin/ksh if (( var >= 1 && var <= 5 )); then .................................. (1 Reply)
Discussion started by: yongho
1 Replies

3. Shell Programming and Scripting

(probably stupidly simple) if [ $var1 = $var2 ] problem...

OK, while I'm not new to the Mac or some of the the inner workings of Mac OS X I am quite new to scripting. And while I have "Learning the Bash Shell" by those lovely people at O'Reilly (Cameron Newham et. al.) I'm missing something, I just know I am. Here's the problem: At the beginning of... (2 Replies)
Discussion started by: woodgie
2 Replies

4. UNIX for Dummies Questions & Answers

What is this? var2=${var1#??????????}

Googling the answer to this question just doesn't work when Google won't search your symbols for you. Can someone tell me what this command will assign to var2, and where I can find more information about using braces in this way? var2=${var1#??????????} Thanks so much. (2 Replies)
Discussion started by: blondie53403
2 Replies

5. Shell Programming and Scripting

concatenate varaibles var1, var2 together to var1 again

HI i like to concatenate the two variables var1=$line (ie 22885068900000652 B86860003OLFXXX592123320081227) var2=$amount (ie 123456) i want to club together both the above varaible var1 & var2 and assign back to var1 right now i am doing like this but it is not working. var1=`echo... (1 Reply)
Discussion started by: kshuser
1 Replies

6. Shell Programming and Scripting

Convert .../($var1|$var2)/... regex to string

Hello, In one part of my shell program I need to translate many of lines in the following pattern : /(folder1|...|folderN)/(sub1|...|subN)/.../(file1|...|fileN) into strings : /folder1/sub1/.../file1 /folder1/sub1/.../... /folder1/sub1/.../fileN ... /folderN/subN/.../fileN the... (2 Replies)
Discussion started by: Ghadamyari
2 Replies

7. Shell Programming and Scripting

Basic bash, echo in loop for

Hi, I am trying to make a script to manage log. I want to write the name of the .gz I moved and the date : for i in `ls $replog/*.gz` do echo " $i " `echo $i date +%d:%m:%Y` `echo $datee `>> $replog/mrnet.log mv $i /var/log/vieux-logs done I need to echo... (10 Replies)
Discussion started by: Dabless
10 Replies

8. Shell Programming and Scripting

Echo with loop

Hello i have a file with this format: ip.txt content: 192.168.1.1/2020 192.136.1.2/2028 192.168.1.10/3047 .... need to create 1000 files and each files content, import data from ip.txt line (first file with first line data, second file with second line...etc) internal=yes internalip=... (14 Replies)
Discussion started by: nimafire
14 Replies

9. Shell Programming and Scripting

Echo print on same line while loop using variable

Currently using below script but echo it print the output in two line. Input file all-vm-final-2.txt CEALA08893 SDDC_SCUN DS_SIO_Workload_SAPUI_UAT_01 4 CEALA09546 SDDC_SCUN DS-SIO-PD5_Workload_UAT_SP1_Flash_07 4 CEALA09702 SDDC_SCUN DS-VSAN-RMP-WORKLOAD01 4 DEALA08762 SDDC_LDC... (3 Replies)
Discussion started by: ranjancom2000
3 Replies

10. UNIX for Beginners Questions & Answers

Echo For ... Loop output into a file

Hi, All: I have one for ... loop code to generate a list of rename statement. However, echo the loop output on screen is OK. But store the echo output into a file is not working. So come here to seek help. My basic code is: ! /bin/ksh echo > DAS_VetFed.txt dir=/mydirectory cd $dir files=`ls... (6 Replies)
Discussion started by: duke0001
6 Replies
QAxScript(3qt)															    QAxScript(3qt)

NAME
QAxScript - Wrapper around script code SYNOPSIS
This class is part of the Qt ActiveQt Extension. #include <qaxscript.h> Inherits QObject. Public Members enum FunctionFlags { FunctionNames = 0, FunctionSignatures } QAxScript ( const QString & name, QAxScriptManager * manager ) ~QAxScript () bool load ( const QString & code, const QString & language = QString::null ) QStringList functions ( FunctionFlags flags = FunctionNames ) const QString scriptCode () const QString scriptName () const QAxScriptEngine * scriptEngine () const QVariant call ( const QString & function, const QVariant & var1 = QVariant ( ), const QVariant & var2 = QVariant ( ), const QVariant & var3 = QVariant ( ), const QVariant & var4 = QVariant ( ), const QVariant & var5 = QVariant ( ), const QVariant & var6 = QVariant ( ), const QVariant & var7 = QVariant ( ), const QVariant & var8 = QVariant ( ) ) QVariant call ( const QString & function, QValueList<QVariant> & arguments ) Signals void entered () void finished () void finished ( const QVariant & result ) void finished ( int code, const QString & source, const QString & description, const QString & help ) void stateChanged ( int state ) void error ( int code, const QString & description, int sourcePosition, const QString & sourceText ) DESCRIPTION
This class is defined in the Qt ActiveQt Extension, which can be found in the qt/extensions directory. It is not included in the main Qt API. The QAxScript class provides a wrapper around script code. Every instance of the QAxScript class represents a piece of scripting code in a particular scripting language. The code is loaded into the script engine using load(). Functions declared in the code can be called using call(). The script provides scriptEngine() provides feedback to the application through signals. The most important signal is the error() signal. Direct access to the QAxScriptEngine is provided through the scriptEngine() function. Warning: This class is not available with the bcc5.5 and MingW compilers. Member Type Documentation QAxScript::FunctionFlags This FunctionFlags enum describes formatting for function introspection. QAxScript::FunctionNames - Only function names are returned. QAxScript::FunctionSignatures - Returns the functions with signatures. MEMBER FUNCTION DOCUMENTATION
QAxScript::QAxScript ( const QString & name, QAxScriptManager * manager ) Constructs a QAxScript object called name and registers it with the QAxScriptManager manager. This is usually done by the QAxScriptManager class when loading a script. A script should always have a name. A manager is necessary to allow the script code to reference objects in the application. The manager takes ownership of the object. QAxScript::~QAxScript () Destroys the object, releasing all allocated resources. QVariant QAxScript::call ( const QString & function, const QVariant & var1 = QVariant ( ), const QVariant & var2 = QVariant ( ), const QVariant & var3 = QVariant ( ), const QVariant & var4 = QVariant ( ), const QVariant & var5 = QVariant ( ), const QVariant & var6 = QVariant ( ), const QVariant & var7 = QVariant ( ), const QVariant & var8 = QVariant ( ) ) Calls function, passing the parameters var1, var1, var2, var3, var4, var5, var6, var7 and var8 as arguments and returns the value returned by the function, or an invalid QVariant if the function does not return a value or when the function call failed. See QAxScriptManager::call() for more information about how to call script functions. QVariant QAxScript::call ( const QString & function, QValueList<QVariant> & arguments ) This is an overloaded member function, provided for convenience. It behaves essentially like the above function. Calls function passing arguments as parameters, and returns the result. Returns when the script's execution has finished. See QAxScriptManager::call() for more information about how to call script functions. void QAxScript::entered () [signal] This signal is emitted when a script engine has started executing code. void QAxScript::error ( int code, const QString & description, int sourcePosition, const QString & sourceText ) [signal] This signal is emitted when an execution error occured while running a script. code, description, sourcePosition and sourceText contain information about the execution error. void QAxScript::finished () [signal] This signal is emitted when a script engine has finished executing code. void QAxScript::finished ( const QVariant & result ) [signal] This is an overloaded member function, provided for convenience. It behaves essentially like the above function. result contains the script's result. This will be an invalid QVariant if the script has no return value. void QAxScript::finished ( int code, const QString & source, const QString & description, const QString & help ) [signal] This is an overloaded member function, provided for convenience. It behaves essentially like the above function. code, source, description and help contain exception information when the script terminated. QStringList QAxScript::functions ( FunctionFlags flags = FunctionNames ) const Returns a list of all the functions in this script if the respective script engine supports introspection; otherwise returns an empty list. The functions are either provided with full prototypes or only as names, depending on the value of flags. See also QAxScriptEngine::hasIntrospection(). bool QAxScript::load ( const QString & code, const QString & language = QString::null ) Loads the script source code written in language language into the script engine. Returns TRUE if code was successfully entered into the script engine; otherwise returns FALSE. If language is empty (the default) it will be determined heuristically. If code contains the string End Sub it will be interpreted as VBScript, otherwise as JScript. Additional scripting languages can be registered using QAxScript::registerEngine(). This function can only be called once for each QAxScript object, which is done automatically when using QAxScriptManager::load(). QString QAxScript::scriptCode () const Returns the script's code, or the null-string if no code has been loaded yet. See also load(). QAxScriptEngine * QAxScript::scriptEngine () const Returns a pointer to the script engine. You can use the object returned to connect signals to the script functions, or to access the script engine directly. QString QAxScript::scriptName () const Returns the name of the script. void QAxScript::stateChanged ( int state ) [signal] This signal is emitted when a script engine changes state. state can be any value in the QAxScriptEngineState enumeration. SEE ALSO
http://doc.trolltech.com/qaxscript.html http://www.trolltech.com/faq/tech.html COPYRIGHT
Copyright 1992-2007 Trolltech ASA, http://www.trolltech.com. See the license file included in the distribution for a complete license statement. AUTHOR
Generated automatically from the source code. BUGS
If you find a bug in Qt, please report it as described in http://doc.trolltech.com/bughowto.html. Good bug reports help us to help you. Thank you. The definitive Qt documentation is provided in HTML format; it is located at $QTDIR/doc/html and can be read using Qt Assistant or with a web browser. This man page is provided as a convenience for those users who prefer man pages, although this format is not officially supported by Trolltech. If you find errors in this manual page, please report them to qt-bugs@trolltech.com. Please include the name of the manual page (qaxscript.3qt) and the Qt version (3.3.8). Trolltech AS 2 February 2007 QAxScript(3qt)
All times are GMT -4. The time now is 06:52 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy