Pipe into VIEW and search

I am using;
Code:
TCC  22.00.32 x64   Windows 7 [Version 6.1.7601]

As a test, here is test.txt;
Code:
The
quick
brown
fox
jumped
over
the
lazy
dog

I want to view the file, but start displaying the file at the position of a string match;
Code:
view test.txt /s:jumped

...which works as it should.

When piping into VIEW and doing a search;
Code:
type test.txt | view /s:jumped

...this does not work, that is, view is not launched, no result is returned.

If I pipe into LIST, it does work;
Code:
type test.txt | list /t"jumped"

How can I Pipe into VIEW and search?

Joe
 
Fixed in 22.0.33 (uploaded yesterday).

Just updated to
Code:
TCC  22.00.33 x64   Windows 7 [Version 6.1.7601]

Piping works, but VIEW still returns an errorlevel of 1, as noted in #3.

In TCC 18;
Code:
c:\users\jlc\utils>ver

TCC  18.00.32 x64   Windows 7 [Version 6.1.7601]

c:\users\jlc\utils>view test.txt

c:\users\jlc\utils>echo %_?
0

...in TCC 22;
Code:
c:\users\jlc\utils>ver

TCC  22.00.33 x64   Windows 7 [Version 6.1.7601]

c:\users\jlc\utils>view test.txt

c:\users\jlc\utils>echo %_?
1

Joe
 
It's an external app.
Code:
c:\users\jlc\utils>ver

TCC  18.00.32 x64   Windows 7 [Version 6.1.7601]

c:\users\jlc\utils>view test.txt

c:\users\jlc\utils>echo %?
0

Code:
c:\users\jlc\utils>ver

TCC  22.00.33 x64   Windows 7 [Version 6.1.7601]

c:\users\jlc\utils>view test.txt

c:\users\jlc\utils>echo %?
1

Code:
c:\users\jlc\utils>ver

TCC  22.00.33 x64   Windows 7 [Version 6.1.7601]

c:\users\jlc\utils>view test.txt

c:\users\jlc\utils>echo %errorlevel
1

...still returns an errorlevel of 1 as an external app in TCC 22, but returns 0 in TCC 18.

Joe
 
Code:
c:\users\jlc\utils>ver

TCC  22.00.33 x64   Windows 7 [Version 6.1.7601]

c:\users\jlc\utils>which view
view is an alias : "C:\Program Files\JPSoft\TCMD22\v.exe"

c:\users\jlc\utils>echo %@alias[view]
"C:\Program Files\JPSoft\TCMD22\v.exe"

c:\users\jlc\utils>view test.txt

c:\users\jlc\utils>echo %?
0

The above allows me to use VIEW both as a stand-alone, through a pipe, and returns the correct errorlevel.

Joe
 
May 20, 2008
11,414
99
Syracuse, NY, USA
I'm not sure what should happen here But, how should this work, given that TYPE is internal?
Code:
g:\tc22> type TCMD.INI | view

g:\tc22> echo %? %_?
1 1

g:\tc22> type TCMD.INI | V.exe

g:\tc22> echo %? %_?
0 0
 
Similar threads
Thread starter Title Forum Replies Date
Peter Murschall PIPE Fittings makes Errors Support 3
vefatica DO ... pipe ... simplified Support 11
vefatica DO ... | ... (pipe ends prematurely) Support 18
nikbackm Pipe performance in TCC v20 Support 3
vefatica IFTP problems (broken pipe?) Support 24
G WAD Pipe clears screen Support 2
W redirection with pipe don't work Support 10
S @CON: does not work with sendmail for pipe Support 2
A Escape characters on right side of pipe Support 0
nikbackm Output of non-ascii characters via pipe Support 1
N Can't set an env variable via pipe Support 8
T VIEW only works from command line Support 14
vefatica VIEW ... remember the UTF-8 setting? Support 0
Alpengreis Documentation Minor issue in help file for view /E Support 1
vefatica VIEW wrap searches? Support 2
R Documentation Help Nit > bdebugger View Menu Support 0
Joe Caverly Why does TCCRT return VIEW as an internal command? Support 6
vefatica VIEW ... CommandPrompt ... TC21 ... unregistered Support 6
vefatica Start VIEW with the toolbar showing? Support 5
rps How to? Piping to View /gb Support 1
vefatica VIEW ... remember no toolbar Support 0
E Fixed View command broken in version 21.0 build 22 Support 9
vefatica File Explorer ... remember view settings? Support 5
vefatica "View" settings still not remembered Support 10
vefatica TCMD ... remember View settings? Support 7
C View Print Wrap - please break at whitespace Support 3
C VIEW PRINT /Wrap doesn't work Support 0
C VIEW PRINT - Documentation corrected - Font size Support 8
C WAD VIEW print multiple files - switches fail Support 10
MickeyF TCC v16 crashes when I hit F1 to view help Support 9
R V19 - 'V' and 'View" Support 6
cgunhouse Crash on View/Folder Support 1
M View doesn't recognize Ctrl+End and Ctrl+Pos1 Support 2
vefatica Speaking of VIEW Support 18
nikbackm VIEW broken in v18 + Windows 10 Support 8
Alpengreis [Bug?] View (V) Prefs Error (TC 18.00.27 x64) Support 4
D Fixed Cut and paste in TC's file/folder view does not remove file Support 17
E View (internal command) does nothing now Support 3
vefatica VIEW and chars in 128-255 Support 4
MickeyF where to view the latest JPSoft newsletter? Support 0
Joe Caverly VIEW window in a TCC tab window problems Support 5
vefatica Fixed No text in List View! Support 4
D Folder/List view changed in v15 Support 8
D How to? V15.00.30 -(help!) - Floating view windows don't open Support 1
nikbackm Fixed v15: VIEW - encoding and CSV issues Support 9
T view command not working Support 5
S TCMD No List-View with Libraries? Support 5
M Sync folder/list view with command window? Support 2
C Fixed Starting editor from VIEW Support 9
J VIEW doesn't work again Support 16

Similar threads