Sponsored Content
Homework and Emergencies Homework & Coursework Questions Creating a new file that is composed of other contents Post 302361708 by pludi on Wednesday 14th of October 2009 01:25:32 AM
Old 10-14-2009
To merge 2 files, you will have to concatenate them.
 

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Creating file contents using contents of another file

Hi, I am not sure how to start doing this so I hope to get some advice as to how to start. I have 2 files. The source file contains data that I needed is in columns delimited by ";". For example, in this format: "CONTINENT","COUNTRY","CITY","ID" "asia","japan","tokyo","123"... (21 Replies)
Discussion started by: ReV
21 Replies

2. UNIX for Dummies Questions & Answers

compare 2 file contents , if same delete 2nd file contents

Give shell script....which takes two file names as input and compares the contents, is both are same delete second file's contents..... I try with "diff"...... but confusion how to use "diff" with if ---else Thanking you (5 Replies)
Discussion started by: krishnampkkm
5 Replies

3. Shell Programming and Scripting

Perl help: Creating a multidimensional array of subdirectories and its contents

I'm currently working with dozens of FASTA files, and I'm tired of having to manually change the filename in my Perl script. I'm trying to write a simple Perl script that'll create a 2-dimensional array containing the name of the folders and its contents. For example, I would like the output... (6 Replies)
Discussion started by: shwang3
6 Replies

4. Shell Programming and Scripting

I want to delete the contents of a file which are matching with contents of other file

Hi, I want to delete the contents of a file which are matching with contents of other file in shell scripting. Ex. file1 sheel,sumit,1,2,3,4,5,6,7,8 sumit,rana,2,3,4,5,6,7,8,9 grade,pass,2,3,4,5,6,232,1,1 name,sur,33,1,4,12,3,5,6,8 sheel,pass,2,3,4,5,6,232,1,1 File2... (3 Replies)
Discussion started by: ranasheel2000
3 Replies

5. Shell Programming and Scripting

Replace partial contents of file with contents read from other file

Hi, I am facing issue while reading data from a file in UNIX. my requirement is to compare two files and for the text pattern matching in the 1st file, replace the contents in second file by the contents of first file from start to the end and write the contents to thrid file. i am able to... (2 Replies)
Discussion started by: seeki
2 Replies

6. Shell Programming and Scripting

Folder contents getting appended as strings while redirecting file contents to a variable

Hi one of the output of the command is as below # sed -n "/CCM-ResourceHealthCheck:/,/---------/{/CCM-ResourceHealthCheck:/d;/---------/d;p;}" Automation.OutputZ$zoneCounter | sed 's/$/<br>/' Resource List : <br> *************************** 1. row ***************************<br> ... (2 Replies)
Discussion started by: vivek d r
2 Replies

7. Shell Programming and Scripting

Shell script (sh file) logic to compare contents of one file with another file and output to file

Shell script logic Hi I have 2 input files like with file 1 content as (file1) "BRGTEST-242" a.txt "BRGTEST-240" a.txt "BRGTEST-219" e.txt File 2 contents as fle(2) "BRGTEST-244" a.txt "BRGTEST-244" b.txt "BRGTEST-231" c.txt "BRGTEST-231" d.txt "BRGTEST-221" e.txt I want to get... (22 Replies)
Discussion started by: pottic
22 Replies

8. Shell Programming and Scripting

ksh Script, Reading A File, Grepping A File Contents In Another File

So I'm stumped. First... APOLOGIES... my work is offline in an office that has zero internet connectivity, as required by our client. If need be, I could print out my script attempts and retype them here. But on the off chance... here goes. I have a text file (file_source) of terms, each line... (3 Replies)
Discussion started by: Brusimm
3 Replies

9. UNIX for Beginners Questions & Answers

Output file name and file contents of multiple files to a single file

I am trying to consolidate multiple information files (<hostname>.Linux.nfslist) into one file so that I can import it into Excel. I can get the file contents with cat *Linux.nfslist >> nfslist.txt. I need each line prefaced with the hostname. I am unsure how to do this. --- Post updated at... (5 Replies)
Discussion started by: Kentlee65
5 Replies
XwcLookupString()														 XwcLookupString()

Name
  XwcLookupString - obtain composed wide-character input from an input method.

Synopsis
  int XwcLookupString(ic, event, buffer_return, bytes_buffer,
  keysym_return, status_return)
	XIC ic;
	XKeyPressedEvent *event;
	wchar_t *buffer_return;
	int wchars_buffer;
	KeySym *keysym_return;
	Status *status_return;

Arguments
  ic	       Specifies the input context.

  event        Specifies the keypress event to be used.

  buffer_return
	       Returns a wide-character string (if any) from the input method.

  wchars_buffer
	       Specifies the number of wide-characters in return buffer.

  keysym_return
	       Returns the KeySym computed from the event if this argument is not NULL.

  status_return
	       Returns a value indicating what kind of data is returned.

Returns
  The length, in wide characters, of the string returned in buffer_return, if any.

Availability
  Release 5 and later.

Description
  XwcLookupString()  passes a KeyPress event to an input context, returns composed text in the encoding of the locale of the input context if
  any is ready, and may return a keysym corresponding to the KeyPress event as well.

  There are several possible results of a call to XwcLookupString(), and a client should check the value returned in the status_return	argu-
  ment to determine which has occured.	The possible values are:

  XBufferOverflow
	    The input string to be returned is too large for the supplied buffer_return.  The required size in wide characters is returned as
	    the value of the function, and the contents of buffer_return and keysym_return are not modified.  The client should  re-call  the
	    function with the same event and a buffer of adequate size in order to obtain the string.

  XLookupNone
	    No consistent input has been composed so far.  The contents of buffer_return and keysym_return are not modified, and the function
	    returns zero.

  XLookupChars
	    Some input characters have been composed.  They are placed	in  the  buffer_return	argument,  and	the  string  length  in  wide
	    characters	is  returned  as  the  value  of  the function.  The string is encoded in the locale bound to the input context.  The
	    contents of the keysym_return argument is not modified.

  XLookupKeySym
	    A KeySym has been returned instead of a string and is returned in keysym_return.  The contents of the buffer_return  argument  is
	    not modified, and the function returns zero.

  XLookupBoth
	    Both a KeySym and a string are returned; XLookupChars and XLookupKeySym occur simultaneously.

  When	XwcLookupString() returns a string, the return value of the function is the length, in wide characters, of that string.  The returned
  string is a wide-character string in the encoding of the locale of the input context.  If that  encoding  is	state-dependent,  the  string
  begins in the initial state of the encoding.

  When	both a keysym and a string are returned, the string does not necessarily correspond to the keysym.  An application that is not inter-
  ested in return keysyms can pass a NULL keysym_return

  Note that only KeyPress events should be passed to XwcLookupString().  When KeyRelease events are passed, the resulting behavior  is	unde-
  fined.   It  does  not make any difference if the input context passed as an argument to XmbLookupString() and XwcLookupString() is the one
  currently in possession of the focus or not.	Input may have been composed within an input context before it lost the focus, and that input
  may be returned on subsequent calls to XmbLookupString() or XwcLookupString(), even though it no longer has any more keyboard focus.

See Also
  XLookupKeysym(), XmbLookupString().

Xlib - Internationalized Text Input												 XwcLookupString()
All times are GMT -4. The time now is 02:32 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy