Subj : Re: changing the prompt to show only a few directories To : Klaus Meinhard From : Stan Brown Date : Thu Feb 07 2002 02:17 pm From: Stan.Brown@f3.n342.z1.cereal.mv.com (Stan Brown) Subject: Re: changing the prompt to show only a few directories From: brahms@mindspring.com (Stan Brown) Klaus Meinhard wrote in comp.os.msdos.4dos: >Amit, > >> How can I change the prompt in 4NT so that it only displays a certain >number >> of characters in the prompt? Sometimes when I'm deep inside the >directory >> hierarchy, the prompt takes up an entire line > >take a look at @left, @instr, @right, @if and you'll be able to come up >with a solution that fulfi8lls your need, e.g. (all on one line) > > set prompt=%%@if[%@len[%_cwds] gt >43,%@left[20,%_cwds]...%@right[20,%_cwds],%_cwds] Interesting -- I never realized you could execute functions in the prompt. But if I'm reading the 4DOS help correctly, the single % in the above should all be double %% when this is in a batch file, and the double %% shown should be only a single % when not in a batch file. -- Stan Brown, Oak Road Systems, Cortland County, New York, USA http://oakroadsystems.com/ "What in heaven's name brought you to Casablanca?" "My health. I came to Casablanca for the waters." "The waters? What waters? We're in the desert." "I was misinformed." -- |Fidonet: Stan Brown 1:342/3 | | Origin: The Cereal Port BBS (603)899-3335 199.125.78.133 (1:132/152) --- # Origin: (1:132/152.4) * Origin: Baddog BBS (1:218/903) .