putty with vi result

When I use secureCRT, I can edit a file use vi and after I exit vi, I can see what was in the file. But if I use putty, then after I quit vi, I can't see what's in the file. It hides all the file from editor.
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Set all colour settings to default in Putty, maybe that helps.
Say for instance you're running 'vipw' as root and you edit /etc/shadow. Now after closing the encrypted passwords remain displayed on your screen for anyone to see. Would that be preferable or even wise? A terminal emulates a console. It is not the same and it may not behave the same (it might have scroll-back buffers). A good terminal should adhere to any escape sequences and clean up on closing an editor or pager. This IMHO is not behaviour you should rely on, or even worse, should *want* to change.
xiaoyunwuAuthor Commented:
I understand what you say, unSpawn.

I usually only edit common file, and it's convenient. Is there a way?
Determine the Perfect Price for Your IT Services

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden with our free interactive tool and use it to determine the right price for your IT services. Download your free eBook now!

It depends on the TERM emulation set for your session.   If you change the TERM emulation to 'ansi'(for example) for your putty session, then your problem will be solved.

$ export TERM=ansi

Note: Other programs might not like the 'ansi' terminal emulation, and may display erratically.
I agree with unSpawn but if you really need that feature with putty just go to putty's Configuration/Terminal/Features/ and check "Disable Switching to alternate terminal screen"
After that change when you exit nano or vi  you'll see a black screen but if you scroll up you'll get what your are looking for.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
xiaoyunwuAuthor Commented:
Pmasotta, It's worked after I changed the setting as you told.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.