Sponsored Content
Full Discussion: Query about opening the file
Top Forums Shell Programming and Scripting Query about opening the file Post 302813403 by jaiseaugustine on Monday 27th of May 2013 08:00:51 AM
Old 05-27-2013
That means, you are reading a file and you want to do some editing in that file? If so, press 'i' and start typing. press 'Esc' to go back.
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

opening a file

im trying to open a file in my bin directory and the farthest i can get is into the folder but not the actual file itself i use text edit as the editor. when i try to open the file it says it doesn't exist here is what i type cd bin open cmnds (dir. which it is under) open test no such... (4 Replies)
Discussion started by: hiei
4 Replies

2. Programming

Opening a file during FTP

I need to process a file in real time as it is being FTPed from a remote server. In my test environment, I wrote a process that would: 1) Open the file - fopen(filename, "r") 2) Go to the offset where I left off on the previous itteration (fseek) 3) Read 2K blocks and append each block to a... (1 Reply)
Discussion started by: ceaker
1 Replies

3. Shell Programming and Scripting

how to know whether that file has eol or noeol before opening that file in VI editor

Hi, I want to check whether file has EOL or NOEOL before opening this file in VI editor. My file is very big its in terms of 15-20 MB. I am using ksh for this. When we opened the file in vi editor, normally at last line we are able to see whether this is eol or noeol file. But i does want... (1 Reply)
Discussion started by: HariRaju
1 Replies

4. Shell Programming and Scripting

Deleting lines inside a file without opening the file

Hi, Just consider there are around 10 lines in a file. Now is it possible to delete the first 2 lines in the file without opening the file. No matter whatever the content of the file is, I just wanna delete the first 2 lines without opening the file. Is that possible? If so, please help me out.... (3 Replies)
Discussion started by: toms
3 Replies

5. UNIX for Dummies Questions & Answers

Opening a file in perl

Hi I need to open a file if a condition(for example a if a regular expression) is met. How do i do this ? open (file) if (some regex)..... (3 Replies)
Discussion started by: manutd
3 Replies

6. Shell Programming and Scripting

Shell Script to execute Oracle query taking input from a file to form query

Hi, I need to query Oracle database for 100 users. I have these 100 users in a file. I need a shell script which would read this User file (one user at a time) & query database. For instance: USER CITY --------- ---------- A CITY_A B CITY_B C ... (2 Replies)
Discussion started by: DevendraG
2 Replies

7. Shell Programming and Scripting

Problems with file opening

Hi All, I have a file test.dat. When I view this file using code1 , that time no problem. But when I open this file using code2, that time some lines are missing. I don't know why is the problem occurred. I already convert dos2unix fromat. But problem is not solving. Please help me about the... (3 Replies)
Discussion started by: mnmonu
3 Replies

8. Shell Programming and Scripting

Xmllint - Xml-file problem --ods file not opening

Dear All, this is my first post on this Forum, glad to be here. I'm trying to fix an .ods file. Yes, I had a backup, but it's also corrupted. When opening the document I get this EM: read error format error discovered in the file in sub-document content.xml at 2,337040(row,col). So I... (3 Replies)
Discussion started by: jameslast
3 Replies

9. Shell Programming and Scripting

Opening a file in vi and automatically save and quit this file using shell script

Hi friends, In my shell script, I want to open a file using vi editor. After opening the file in vi, I want to save and quit this file automatically.... all through shell script. the code segment is: ------------------------------------------------------------ cd ~/netfpga/projects/scone/sw/... (2 Replies)
Discussion started by: sachinteotia
2 Replies

10. UNIX for Dummies Questions & Answers

How to read a file without opening the file and delete last line?

I have file called "text". The contents are as below : aaa bbb ccc ddd eee ffff ddd hhhh iiii I want to read this file without opening and and delete the last line. How can it be done? (4 Replies)
Discussion started by: the_hunter
4 Replies
tixTree(n)						       Tix Built-In Commands							tixTree(n)

NAME
tixTree - Create and manipulate tixTree widgets SYNOPSIS
tixTree pathName ?options? SUPER-CLASS The TixTree class is derived from the TixScrolledHList class and inherits all the commands, options and subwidgets of its super-class. STANDARD OPTIONS
TixTree supports all the standard options of a frame widget. See the options(n) manual entry for details on the standard options. WIDGET-SPECIFIC OPTIONS [-browsecmd browseCmd] Specifies a command to call whenever the user browses on an entry (usually by single-clicking on the entry). The command is called with one argument, the pathname of the entry. [-closecmd closeCmd] Specifies a command to call whenever an entry needs to be closed (See the BINDINGS section below). This command is called with one argument, the pathname of the entry. This command should perform appropriate actions to close the specified entry. If the -closecmd option is not specified, the default closing action is to hide all child entries of the specified entry. [-command command] Specifies a command to call whenever the user activates an entry (usually by double-clicking on the entry). The command is called with one argument, the pathname of the entry. [-ignoreinvoke ignoreInvoke] A Boolean value that specifies when a branch should be opened or closed. A branch will always be opened or closed when the user presses the (+) and (-) indicators. However, when the user invokes a branch (by doublc-clicking or pressing <Return>), the branch will be opened or closed only if -ignoreinvoke is set to false (the default setting). [-opencmd openCmd] Specifies a command to call whenever an entry needs to be opened (See the BINDINGS section below). This command is called with one argument, the pathname of the entry. This command should perform appropriate actions to open the specified entry. If the -opencmd option is not specified, the default opening action is to show all the child entries of the specified entry. SUBWIDGETS
Name: hlist Class: TixHList The hierarchical listbox that displays the tree. Name: hsb Class: Scrollbar The horizontal scrollbar subwidget. Name: vsb Class: Scrollbar The vertical scrollbar subwidget. DESCRIPTION
The tixTree command creates a new window (given by the pathName argument) and makes it into a Tree widget. Additional options, described above, may be specified on the command line or in the option database to configure aspects of the Tree widget such as its cursor and relief. The Tree widget can be used to display hierachical data in a tree form. The user can adjust the view of the tree by opening or closing parts of the tree. To display a static tree structure, you can add the entries into the hlist subwidget and hide any entries as desired. Then you can call the autosetmode method. This will set up the Tree widget so that it handles all the open and close events automatically. The above method is not applicable if you want to maintain a dynamic tree structure, i.e, you do not know all the entries in the tree and you need to add or delete entries subsequently. To do this, you should first create the entries in the hlist subwidget. Then, use the set- mode method to indicate the entries that can be opened or closed, and use the -opencmd and -closecmd options to handle the opening and closing events. WIDGET COMMANDS
The tixTree command creates a new Tcl command whose name is the same as the path name of the Tree's window. This command may be used to invoke various operations on the widget. It has the following general form: pathName option ?arg arg ...? PathName is the name of the command, which is the same as the Tree widget's path name. Option and the args determine the exact behavior of the command. The following commands are possible for Tree widgets: pathName autosetmode This command calls the setmode method for all the entries in this Tree widget: if an entry has no child entries, its mode is set to none. Otherwise, if the entry has any hidden child entries, its mode is set to open; otherwise its mode is set to close. pathName cget option Returns the current value of the configuration option given by option. Option may have any of the values accepted by the tixTree command. pathName close entryPath Close the entry given by entryPath if its mode is close. pathName configure ?option? ?value option value ...? Query or modify the configuration options of the widget. If no option is specified, returns a list describing all of the available options for pathName (see Tk_ConfigureInfo for information on the format of this list). If option is specified with no value, then the command returns a list describing the one named option (this list will be identical to the corresponding sublist of the value returned if no option is specified). If one or more option-value pairs are specified, then the command modifies the given widget option(s) to have the given value(s); in this case the command returns an empty string. Option may have any of the values accepted by the tixTree command. pathName getmode entryPath Returns the current mode of the entry given by entryPath. pathName open entryPath Open the entry givaen by entryPath if its mode is open. pathName setmode entryPath mode This command is used to indicate whether the entry given by entryPath has children entries and whether the children are visible. mode must be one of open, close or none. If mode is set to open, a (+) indicator is drawn next the the entry. If mode is set to close, a (-) indicator is drawn next the the entry. If mode is set to none, no indicators will be drawn for this entry. The default mode is none. The open mode indicates the entry has hidden children and this entry can be opened by the user. The close mode indi- cates that all the children of the entry are now visible and the entry can be closed by the user. pathName subwidget name ?args? When no options are given, this command returns the pathname of the subwidget of the specified name. When options are given, the widget command of the specified subwidget will be called with these options. BINDINGS
The basic mouse and keyboard bindings of the Tree widget are the same as the bindings of the HList widget. In addition, the entries can be opened or closed under the following conditions: [1] If the mode of the entry is open, it can be opened by clicking on its (+) indicator or double-clicking on the entry. [2] If the mode of the entry is close, it can be closed by clicking on its (-) indicator or double-clicking on the entry. KEYWORDS
Tix(n),tixHList(n) Tix 4.0 tixTree(n)
All times are GMT -4. The time now is 12:39 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy