Lazarus
Home
Help
TinyPortal
Search
Login
Register
Lazarus
»
Forum
»
Programming
»
General
»
Compiled console application doesn't scroll down
Free Pascal
Website
Downloads
Wiki
Documentation
Bugtracker
Mailing List
Lazarus
Website
Downloads (Laz+FPC)
Packages (OPM)
FAQ
Wiki
Documentation (RTL/FCL/LCL)
Bugtracker
CCR Bugs
IRC channel
GIT
Mailing List
Other languages
Foundation
Website
Useful Wiki Links
Project Roadmap
Getting the Source
Screenshots
How to use the forum
About donations (wiki)
Bookstore
Computer Math and Games in Pascal
(preview)
Lazarus Handbook
Search
Advanced search
Recent
VAR RECORD doesn't work?
by
TRon
[
Today
at 12:30:21 pm]
unit not found (StdCtrls)
by
munair
[
Today
at 12:30:07 pm]
[SOLVED] console app wind...
by
senglit
[
Today
at 12:21:57 pm]
Lazarus and XML
by
Bart
[
Today
at 09:38:45 am]
drop picture from browser
by
Handoko
[
Today
at 07:50:10 am]
Searchkey Tdbf
by
Handoko
[
Today
at 05:56:02 am]
LAMW - (SOLVED) upload fi...
by
Mongkey
[
Today
at 05:20:23 am]
Encapsulating existing fu...
by
TRon
[
Today
at 05:16:22 am]
FPImageException while l...
by
TRon
[
Today
at 03:10:14 am]
Make visual components no...
by
sstvmaster
[September 30, 2023, 11:37:48 pm]
Scrolling TStringGrid
by
jamie
[September 30, 2023, 11:01:01 pm]
Large system, i2C to go w...
by
ccrause
[September 30, 2023, 08:52:34 pm]
[ solved ] drawn lines no...
by
Jumbo
[September 30, 2023, 12:00:30 pm]
ZenGL Update +android + M...
by
Seenkao
[September 30, 2023, 12:16:22 am]
Notarization under macOS ...
by
TRon
[September 29, 2023, 11:10:27 pm]
Image not shown after use...
by
Jumbo
[September 29, 2023, 10:14:11 pm]
Saving a Form state (rela...
by
Curt Carpenter
[September 29, 2023, 07:46:53 pm]
Poor optimization of cons...
by
440bx
[September 29, 2023, 06:55:50 pm]
Accessing JSON data from ...
by
magleft
[September 29, 2023, 02:22:30 pm]
Operator not Overloaded E...
by
cdbc
[September 29, 2023, 01:15:28 pm]
Can't hide main window
by
zeljko
[September 29, 2023, 08:16:40 am]
“case (a,b) of...” doesn’...
by
440bx
[September 29, 2023, 08:02:32 am]
sslsockets, TSSLSocketHan...
by
r.lukasiak
[September 29, 2023, 07:55:25 am]
Cross platform DirectoryW...
by
r.lukasiak
[September 29, 2023, 07:44:18 am]
Passing TDate parameter i...
by
Arskin_Fertrubble
[September 29, 2023, 03:54:53 am]
« previous
next »
Print
Pages: [
1
]
Author
Topic: Compiled console application doesn't scroll down (Read 5285 times)
kulverstukas
Guest
Compiled console application doesn't scroll down
«
on:
April 19, 2010, 08:56:11 pm »
Hey,
I have this problem and I have no idea what is wrong. My compiled console application doesn't scroll down when a lot of stuff must be written out (writeln()
. Instead it just overwrites everything so it would fit on the screen. This wasn't happening with old 1.0.6 compiler. When I compile with the newest one, 2.4.0 - that thing happens.
Here is my code:
http://evilzone.org/paste/pastebin.php?show=224
Logged
Leledumbo
Hero Member
Posts: 8700
Programming + Glam Metal + Tae Kwon Do = Me
Re: Compiled console application doesn't scroll down
«
Reply #1 on:
April 20, 2010, 06:25:42 am »
Remove Crt from your uses clause (it registers a video driver that's incompatible with standard console behavior), use Video unit to manipulate cursor position.
Logged
Follow this if you want me to answer:
http://wiki.lazarus.freepascal.org/Lazarus_Faq#What_is_the_correct_way_to_ask_questions_in_the_forum.3F
http://pascalgeek.blogspot.com
https://bitbucket.org/leledumbo
https://github.com/leledumbo
Code first, think later - Natural programmer B)
kulverstukas
Guest
Re: Compiled console application doesn't scroll down
«
Reply #2 on:
April 20, 2010, 07:34:03 pm »
But then nothing works... ClrScr, TextColor, Readkey, GotoXY and other stuff.
Logged
Leledumbo
Hero Member
Posts: 8700
Programming + Glam Metal + Tae Kwon Do = Me
Re: Compiled console application doesn't scroll down
«
Reply #3 on:
April 21, 2010, 06:26:38 am »
It can still be done though Keyboard and Video units, though the way will be very different. For example, ReadKey is roughly the same as GetKeyEventChar(TranslateKeyEvent(GetKeyEvent)). You may want to wrap this in a function to ease calling.
See the docs of relevant units below:
Keyboard:
http://www.freepascal.org/docs-html/rtl/keyboard/index.html
Video:
http://freepascal.org/docs-html/rtl/video/index.html
Logged
Follow this if you want me to answer:
http://wiki.lazarus.freepascal.org/Lazarus_Faq#What_is_the_correct_way_to_ask_questions_in_the_forum.3F
http://pascalgeek.blogspot.com
https://bitbucket.org/leledumbo
https://github.com/leledumbo
Code first, think later - Natural programmer B)
Print
Pages: [
1
]
« previous
next »
Lazarus
»
Forum
»
Programming
»
General
»
Compiled console application doesn't scroll down
TinyPortal
© 2005-2018