Recent

Author Topic: [Solved] Virtual tree demos  (Read 3218 times)

bobonwhidbey

  • Hero Member
  • *****
  • Posts: 502
    • Double Dummy Solver - free download
[Solved] Virtual tree demos
« on: June 14, 2021, 07:07:26 pm »
I'm trying to learn about the virtual tree components by studying the demos and reading the CHM help file. The CHM help file downloaded from GetHub has 2.4 MB but there doesn't seem to be any content....just index. See attached jpg.

The minimal demo program, and some other demos, include a 2nd window with [HINT] info. See attachment. How can I remove this window from the project?
« Last Edit: June 15, 2021, 12:35:50 am by bobonwhidbey »
Win10 64-bit / Lazarus 32-bit 2.0.12 / FPC 3.2.0

wp

  • Hero Member
  • *****
  • Posts: 8576
Re: Virtual tree demos
« Reply #1 on: June 14, 2021, 07:27:54 pm »
I'm trying to learn about the virtual tree components by studying the demos and reading the CHM help file. The CHM help file downloaded from GetHub has 2.4 MB but there doesn't seem to be any content....just index. See attached jpg.
This is another annoyance when Microsoft eagerly had introduced a new feature (the chm help format), but later they noticed that they had opened a lot of security issues and they fixed it by inhibiting user access to this feature.

In this case it is the potential issue that the downloaded file might be harmful and prevents access to it. But you can by-pass this barrier when you right-click on the chm file in the explorer and select Properties. At the bottom of the "general" tab there's a checkbox saying that this file is from another computer and possibly poses a security issue, but you are allowed to access the file by checking the checkbox. Of course at your own risk  ;D

This is for Windows 10. Maybe Windows 7 was less restrictive, but if not, the issue probably can be handled in a similar way.


The minimal demo program, and some other demos, include a 2nd window with [HINT] info. See attachment. How can I remove this window from the project?
You mean the second black Window? This is the console output. You can disable it normally by going to the Project Options and checking the "Win32 gui application" checkbox under "Compiler Options" > "Config and Target" (by default it is checked, but programmers sometimes turn it off to see debug output).
Mainly Lazarus trunk / fpc 3.2.0 / all 32-bit on Win-10, but many more...

bobonwhidbey

  • Hero Member
  • *****
  • Posts: 502
    • Double Dummy Solver - free download
Re: [Solved] Virtual tree demos
« Reply #2 on: June 14, 2021, 07:59:51 pm »
I was premature in noting this as 'solved'.  The first question (console window) was solved but not the CHM file problem.  I checked the correct property on the General tab, but no change appeared.  I still can not view the content of various pages - just the index.
Win10 64-bit / Lazarus 32-bit 2.0.12 / FPC 3.2.0

wp

  • Hero Member
  • *****
  • Posts: 8576
Re: Virtual tree demos
« Reply #3 on: June 14, 2021, 11:18:56 pm »
Mainly Lazarus trunk / fpc 3.2.0 / all 32-bit on Win-10, but many more...

bobonwhidbey

  • Hero Member
  • *****
  • Posts: 502
    • Double Dummy Solver - free download
Re: Virtual tree demos
« Reply #4 on: June 15, 2021, 12:35:11 am »
That did it.   ;D All I had to do was move the CHM file out of the Downloads folder to another place (Desktop, etc.). Moral of the story - move files out of the Downloads folder.

Thank you,
Win10 64-bit / Lazarus 32-bit 2.0.12 / FPC 3.2.0

Nimral

  • Full Member
  • ***
  • Posts: 175
  • Keep it simple.
Re: [Solved] Virtual tree demos
« Reply #5 on: June 15, 2021, 10:07:41 am »
U are sure?

I regularly get this issue when I download chm files from the internet. What I need to do is, after download, right-click the file and select "unblock".

IMHO the folder isn't the cause. I just tested it in Windows 10 ... as soon as I removed the block flag, the chm displayed fine from the "Downloads" folder. Maybe you copied the file in a way so the block flag was removed?

« Last Edit: June 15, 2021, 10:11:11 am by Nimral »
Lazarus 2.0.12 & 2.3.0  (trunk) on Windows 10, Raspberry Pi OS "Buster", macOS Catalina, macOS BigSur, VMWare Workstation 15

marcov

  • Administrator
  • Hero Member
  • *
  • Posts: 9456
  • FPC developer.
Re: [Solved] Virtual tree demos
« Reply #6 on: June 15, 2021, 01:11:20 pm »
The flag can get lost if you copy to a filesystem type (read: non NTFS) that doesn't support the forked files that hold the lock. This CHM lock has existed since Windows XPsp2, so quite a while.

FPC also supports a commandline solution to do this, using "chmls unblock <x>"

bobonwhidbey

  • Hero Member
  • *****
  • Posts: 502
    • Double Dummy Solver - free download
Re: [Solved] Virtual tree demos
« Reply #7 on: June 15, 2021, 05:11:15 pm »
Yes - I first checked 'unblock'.  If I copy and move the .chm file to any other folder but Downloads, it displays correctly. If I copy it to the Downloads folder, it looks like that attached.
Win10 64-bit / Lazarus 32-bit 2.0.12 / FPC 3.2.0

 

TinyPortal © 2005-2018