I'm using the following command to test for certain characters in a script
echo "${1}" | grep '\$'
if (( ${?} == 0 ))
then
testing this script on the command line I have
ksh -x script1.sh "xxxx$xxxx"
this works fine but when I want to use
ksh -x script1.sh "xxxx $xxx"
the... (1 Reply)
Hi,
I'm trying to do the following , I have certain variables in a file and then I want to check for these variables in a certain cobol file to see if they contain a certain package if so replace them with value 1 but but that last line is giving problems:
# for each variable in SQL file
... (1 Reply)
Hi guys,
I want to replace certain values with the number 1.
But it is also replacing other values which contain the value I want to replace. e.g.:
I want to replace ID-INTERNAL with 1, that's no problem but it will also replace ID-INTERNAL-NON-REM with 1-NON-REM
I don't want to... (10 Replies)
I am looking for 8 variables in the following profile. I am looking to see if anyone could explain this for me better than the book I am using has been able to. There are 5 system, 2 aliases, and one editor. The profile is as follows:
# @(#)local.profile 1.8 99/03/26 SMI
stty istrip... (0 Replies)
Hi,
I want to append some data at end of file , so i use following
sed '$a/data=$var' file
But by this method i am not able to substitue value of $var, & if i use " in place of ', then $a, gives me problem.
Any suggestions?
-Sarbjit (4 Replies)
Hi everybody, im trying to store a path "address" of a file in a variable, then IF the Address that the user entered INSIDE the variable is exist, do something, else echo invalid file address.
here's my code, but it's not working i dunno why:
$variable
cat > variable
#variable will contain... (4 Replies)
Hi
I am trying to find were to look for definitions of these variables; $0, $1, $2, $#, $$ , $*. I am not having much luck with my searching. Can anyone point me in the right direction?
Thanks, Doug (3 Replies)
Hello guys! It's orszhak and in my book I am currently studying incrementing values in c++ and it states thant I could do this to increment the value of nVariable nVariable = nVariable + 2; it states that I could also do this and assign the same value nVariable += 2; but can't I also do this and... (1 Reply)
I have 2 scripts first script would call second script.
test1.sh
#!/bin/bash
logfile=`basename $0`.log
echo "First File" >> $logfile
TIME=`ls -lu array.ksh | awk '{print $6" "$7" "$8}'`
. /home/infrmtca/bin/Test/test2.sh
#/home/infrmtca/bin/Test/test2.sh
test2.sh
#!/bin/bash... (1 Reply)
Discussion started by: Ariean
1 Replies
LEARN ABOUT CENTOS
xmrendertableaddrenditions
XmRenderTableAddRenditions(library call) XmRenderTableAddRenditions(library call)
NAME
XmRenderTableAddRenditions -- Creates a new render table
SYNOPSIS
#include <Xm/Xm.h>
XmRenderTable XmRenderTableAddRenditions(
XmRenderTable oldtable,
XmRendition *renditions,
Cardinal rendition_count,
XmMergeMode merge_mode);
DESCRIPTION
XmRenderTableAddRenditions is a function to create a new render table that includes the renditions listed in oldtable, if there is one.
This function also copies specified renditions (renditions) to the new render table. The first rendition_count renditions of the renditions
array are added to the new table. If a rendition is tagged with a tag that matches a tag already in oldtable, then the existing rendition
using that tag is either modified or freed and replaced with the new rendition, depending on the value of merge_mode. If oldtable is NULL,
XmRenderTableAddRenditions creates a new render table containing only the specified renditions.
This function deallocates the original render table after extracting the required information. It is the responsibility of the caller to
free the renditions of the renditions array by calling the XmRenditionFree function.
oldtable Specifies the render table to be added to.
renditions
Specifies an array of renditions to be added.
rendition_count
Specifies the number of renditions from renditions to be added.
merge_mode
Specifies what to do if the XmNtag of a rendition matches that of one that already exists in oldtable. The possible values are as
follows:
XmMERGE_REPLACE
Completely replaces the old rendition with the new one.
XmMERGE_OLD
Replaces any unspecified values of the old rendition with the corresponding values from the new rendition.
XmMERGE_NEW
Replaces the old rendition with the new rendition, replacing any unspecified values of the new rendition with the cor-
responding values from the old rendition.
XmSKIP Skips over the new rendition, leaving the old rendition intact.
RETURN
If renditions is NULL or rendition_count is 0 (zero), this function returns oldtable. Otherwise, the function returns a new XmRenderTable.
The function allocates space to hold this new render table. The application is responsible for managing this allocated space. The appli-
cation can recover the allocated space by calling XmRenderTableFree.
RELATED XmRendition(3) and XmRenderTableFree(3).
XmRenderTableAddRenditions(library call)