Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

xmlistreplaceitemspos(3) [centos man page]

XmListReplaceItemsPos(library call)									       XmListReplaceItemsPos(library call)

NAME
XmListReplaceItemsPos -- A List function that replaces the specified elements in the list SYNOPSIS
#include <Xm/List.h> void XmListReplaceItemsPos( Widget widget, XmString *new_items, int item_count, int position); DESCRIPTION
XmListReplaceItemsPos replaces the specified number of items of the List with new items, starting at the specified position in the List. When the items are inserted into the list, they are compared with the current XmNselectedItems list. If any of the new items matches an item on the selected list, it appears selected. widget Specifies the ID of the List widget. new_items Specifies the replacement items. item_count Specifies the number of items in new_items and the number of items in the list to replace. This number must be nonnegative. position Specifies the position of the first item in the list to be replaced. A value of 1 indicates that the first item replaced is the first item in the list; a value of 2 indicates that it is the second item; and so on. Beginning with the item specified in position, item_count items in the list are replaced with the corresponding elements from new_items. That is, the item at position is replaced with the first element of new_items; the item after position is replaced with the second element of new_items; and so on, until item_count is reached. For a complete definition of List and its associated resources, see XmList(3). RELATED
XmList(3). XmListReplaceItemsPos(library call)

Check Out this Related Man Page

XmListReplaceItemsPosUnselected(library call)							     XmListReplaceItemsPosUnselected(library call)

NAME
XmListReplaceItemsPosUnselected -- A List function that replaces items in a list without selecting the replacement items SYNOPSIS
#include <Xm/List.h> void XmListReplaceItemsPosUnselected( Widget widget, XmString *new_items, int item_count, int position); DESCRIPTION
XmListReplaceItemsPosUnselected replaces the specified number of items in the list with new items, starting at the given position. The replacement items remain unselected, even if they currently appear in the XmNselectedItems list. widget Specifies the ID of the List widget to replace items in. new_items Specifies a pointer to the replacement items. item_count Specifies the number of elements in new_items and the number of items in the list to replace. This number must be nonnegative. position Specifies the position of the first item in the list to be replaced. A value of 1 indicates that the first item replaced is the first item in the list; a value of 2 indicates that it is the second item; and so on. Beginning with the item specified in position, item_count items in the list are replaced with the corresponding elements from new_items. That is, the item at position is replaced with the first element of new_items; the item after position is replaced with the second element of new_items; and so on, until item_count is reached. For a complete definition of List and its associated resources, see XmList(3). RELATED
XmList(3). XmListReplaceItemsPosUnselected(library call)
Man Page

14 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Comparing items in 2 files

Hi, I have 2 files with contents in them and I need to compare each item in each file. File1: item4 item5 File2: item2 item3 item5 item6 The items names can be of different lengths. If the items in the File1 are not in File2, delete the missing item in File1. The resulting... (12 Replies)
Discussion started by: ReV
12 Replies

2. Shell Programming and Scripting

sending control c in the loop

I want to go through the list of items and run it. while running it, some of them will have either >there is no response # and then end it... so that it can go to next item OR >there is response # but in order to break out of it, u need to do Control c. How do you send control... (6 Replies)
Discussion started by: hankooknara
6 Replies

3. UNIX for Dummies Questions & Answers

How to get the script corrected to get the solution

Can anyone help it out, My Requirement: Actually i grep for the items in the atrblist (Result of it will provide the line where the item present and also the next line of where it presents)then it will be stored in $i.txt From tat result i wil grep 2nd word after getdate() word and store... (2 Replies)
Discussion started by: prsam
2 Replies

4. Shell Programming and Scripting

Plain Text List to HTML List

Hello, I am trying to take a simple list (from echo, not a file) and turn it into a list with HTML codes. List item one. List item two. List item three. to <ol> <li>List item one.</li> <li>List item two.</li> <li>List item three.</li> </ol> The list is coming in via echo on... (4 Replies)
Discussion started by: QuestunAthority
4 Replies

5. UNIX for Dummies Questions & Answers

replace 0 with R at position 40

i have this contents: H,0100, 4022,FISHER810,6109566,,,,,0,562032, D,0100, 4022,FISHER810,6109566,,1,,,0,562032 if i see 0 at position 40, i want to replace with R. (7 Replies)
Discussion started by: tjmannonline
7 Replies

6. Shell Programming and Scripting

Compare 2 files

HI I have a list of items in 2 files. Some items are present in both the files in any order. Say for example item name is 'apple', it may be present in line 2 of file 1 and line 10 of file 2. I want to see the missing items only. In simple terms, Items present in file1 if not in file2 then... (5 Replies)
Discussion started by: PrasannaKS
5 Replies

7. Shell Programming and Scripting

Replacing content from a list

Okay, so I am not quite sure the best way of going about this. I have a whole stack of files that need items replaced with a code corresponding to it. In particular, I am looking to replace the names of countries with the two letter iso country code. The files themselves are in csv format with... (4 Replies)
Discussion started by: johnlee
4 Replies

8. Shell Programming and Scripting

Sed position specific replace

I'm drawing a blank on how to use sed to replace selectively based on position in the string (vs nth occurence): hello.|there.|how.|are.|you.| I want the period removed in the 3rd item (as defined by the pipe delimiter) if a period is present. So the result in this case would be: ... (2 Replies)
Discussion started by: tiggyboo
2 Replies

9. Shell Programming and Scripting

Sed -f alternatives?

I have a list of items (control file) that I want to substitute in a text file, and it's BIG. The file has two items, the original, and the new: A B B C D E The file has something like 10,000 entries. So in the oldfile.txt, I'd like to basically make all these expression matched... (9 Replies)
Discussion started by: twoblink
9 Replies

10. UNIX for Dummies Questions & Answers

[Solved] Delete files with condition

I have a directory containing thousands of items “video files”, these items were generated by an application, which generates two items with the same name but with different extensions “.avi and .mp4”. There was a tool in my application to remove one item @ a time. Later I found this tool removes... (5 Replies)
Discussion started by: awadeid
5 Replies

11. Shell Programming and Scripting

Read from "list1" and list matches in "list2"

I want to print any matching IP addresse in List1 with List 2; List 1 List of IP addresses; 161.85.58.210 250.57.15.129 217.23.162.249 74.76.129.101 30.221.177.237 3.147.200.59 170.58.142.64 127.65.109.33 150.167.242.146 223.3.20.186 25.181.180.99 2.55.199.32 (3 Replies)
Discussion started by: lewk
3 Replies

12. Shell Programming and Scripting

How can I set up this loop?

I want to compare two files. I think using grep is the way to go but I do not know how to set this up. Let me show an example: File1 has 1000 items, File2 has 700 items I need to take the first item in File1 and search the entire contents of File2 to see if there is a match there. IF there is a... (3 Replies)
Discussion started by: castrojc
3 Replies

13. AIX

List LPAR from VIOS

Hi guys, does anyone know how to get a list of the LPAR running on VIOS? Thanks! (5 Replies)
Discussion started by: cecco16
5 Replies

14. Shell Programming and Scripting

Associative Array with more than one item per entry

Hi all I have a problem where i have a large list ( up to 1000 of items) and need to have 2 items pulled from it into variables in a bash script my list is like the following and I could have it as an array or possibly an external text file maintained separately. Every line is different and... (6 Replies)
Discussion started by: kcpoole
6 Replies