Ported my old TP7 code to FPC without changes lazarus / 8-Other ---------------------------------------------------------------------- anyone · 2020-10-12 15:04 I have a lot of TP7 code made 20 years ago, among them, some were using Turbo Vision, and some were command-line interface (CLI). Recently, I understand that FPC has Free Vision which is equivalent to Turbo Vision. I tried the Free Vision demo and it was quite good (the only thing that did not work was mouse) I have this particular compression library unit written in TP7 based on RLE (or RLE-alike algorithm). I can ported it to FPC without single changes. Though, when I tried to ported it to Delphi 10.xxx(?), it says it does not support the BlockRead in such a way: Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i       {$I-}      Seek(InputFile,SegmentIndex*64000);      BlockRead(InputFile,Data^,64000,AccessStatus);      {$I+}  Does anyone know why? I ended up supporting file less than 64KB on Windows version (instead of multiple 64KB chunk R/W access) of my compression utility. I am not sure if anyone would find my COMPRESS.pas useful. I used a pair of two funny words "Squeeze"(compress) and "Stretch"(expand). The compression ratio is very limited (in real world scenario), maybe worthwhile for learning purposes only? Then there are some TP7 programs of mine which access screen buffer B800:0 directly. I will keep them in archive.org anyway, because no more direct memory access in post-DOS era. ---------------------------------------------------------------------- AlexTP · 2020-10-12 15:38 You can create GitHub account. No need to install git. Using only website, you can  make the repo. And upload all files there (button "add file"). ---------------------------------------------------------------------- marcov · 2020-10-12 17:45 Please reproduce the errormessage. Possibly it is just the VAR parameter acccesstatus, which is word in 16-bit versions, and longint in 32-bits version. FPC probably does both, in unit dos the 16-bit and in in $mode delphi/objfpc the 32-bit ---------------------------------------------------------------------- winni · 2020-10-12 18:16 Hi! We don't know your error message. But this works: Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i type  DataType=array [0..63999] of byte; var  Data:  DataType;..... BlockRead(InputFile,Data[0],64000,AccessStatus);   Winni ---------------------------------------------------------------------- anyone · 2020-10-12 19:35 Quote from: marcov on October 12, 2020, 07:45:01 pmPlease reproduce the errormessage. Possibly it is just the VAR parameter acccesstatus, which is word in 16-bit versions, and longint in 32-bits version. FPC probably does both, in unit dos the 16-bit and in in $mode delphi/objfpc the 32-bit Thanks for your help. It says: [dcc32 Error] COMPRESS.PAS(86): E2008 Incompatible types ---------------------------------------------------------------------- anyone · 2020-10-12 19:40 Quote from: winni on October 12, 2020, 08:16:27 pmHi! We don't know your error message. But this works: Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i type  DataType=array [0..63999] of byte; var  Data:  DataType;..... BlockRead(InputFile,Data[0],64000,AccessStatus);   Winni Thank you for trying to help. I removed the pointer, and now uses Data[0], the error now is: [dcc32 Error] COMPRESS.PAS(86): E2008 Incompatible types ---------------------------------------------------------------------- anyone · 2020-10-12 19:41 Quote from: Alextp on October 12, 2020, 05:38:41 pmYou can create GitHub account. No need to install git. Using only website, you can  make the repo. And upload all files there (button "add file"). Thanks pal. I do have two of them, but none of them attract any traffic.... ---------------------------------------------------------------------- marcov · 2020-10-12 19:49 Quote from: anyone on October 12, 2020, 09:35:53 pmThanks for your help. It says: [dcc32 Error] COMPRESS.PAS(86): E2008 Incompatible types Incomplete, widen the window. ---------------------------------------------------------------------- anyone · 2020-10-12 19:54 Quote from: marcov on October 12, 2020, 09:49:55 pmQuote from: anyone on October 12, 2020, 09:35:53 pmThanks for your help. It says: [dcc32 Error] COMPRESS.PAS(86): E2008 Incompatible types Incomplete, widen the window. Okay, sir. ---------------------------------------------------------------------- anyone · 2020-10-12 19:58 Quote from: marcov on October 12, 2020, 07:45:01 pmPlease reproduce the errormessage. Possibly it is just the VAR parameter acccesstatus, which is word in 16-bit versions, and longint in 32-bits version. FPC probably does both, in unit dos the 16-bit and in in $mode delphi/objfpc the 32-bit Yes, you'right! After I changed to longint, it has no more issues......