Page 5 of 9

Re: ViewError - HMG building utility

Posted: Sun Feb 12, 2017 9:09 pm
by RPC
Hi Pablo
Trying to run ViewError. Installed at c:\ViewError but it doesn't show errors as in screenshots provided by you.
It is neither getting uninstalled by selecting uninstall checkbox.
There is ViewError icon at taskbar and when i click it the ViewError screen and Source code editor preence dialog box appears but uninstall doesn't work
Pls guide.

ViewError - HMG building utility

Posted: Sun Feb 12, 2017 9:54 pm
by Pablo César
Hi Rajeev,

Thanks for your interest and report your difficulties.

ViewError when run for the first time will create one .INI file in the current location of the executable. It will also create an environment variable where it will register where the application is located. This "if" you confirm in button "SAVE" (see picture below):


In this way Build.bat will recognize that there is an ERROR.LOG viewer application.
It is therefore recommended that you store this application in a more appropriate folder than the main directory.
I've stored it in a sub folder called HMGTools. (together with Call_IDE app) ;)

The uninstall option will only work if the application is actually configured. Hence it will delete the environment variable and will no longer work as ERROR.LOG viewer.

When you save the application, that is, configure the application. Take advantage of it and set it with the text editor "Notepad ++" (* #1) and leave the parameter "-n" that will go straight to the line where the error is occurring. This application makes a lot of progress in my compilations. Be it on the command line as well as in builds through the IDE.

  • #1: Use Notepad++ option in ViewError only if you have installed already the Notepad++ in your computer, as your favorite source codes editor.
  • #2: You can install and configure another text editor. But configure it if this editor has the parameterization feature that when opening the editor can position itself in line # <nNumber_of_line> where the error occurs.
    If your favorite editor does not have this feature: let viewError working only through the "Grid as editor" option.

Re: ViewError - HMG building utility

Posted: Mon Feb 13, 2017 2:40 pm
by RPC
Thanks Pablo It is working now.

ViewError - HMG building utility

Posted: Mon Feb 13, 2017 3:47 pm
by Pablo César
Good ! :D

Thank you for your feedback.

ViewError - HMG building utility

Posted: Wed Mar 01, 2017 1:44 am
by Pablo César
Hi all,

As I explained earlier, this application is intended to show and position itself in the line of your source code where the compilation error occurred.
This is working FINE ! :D

However, there are other types of errors that can occur during compilation and are often not related to the line of your code.
It is errors coming from HBMK2, WINDRES and even the operating system (permissions or memory errors, among others).

Now these errors can be viewed more comprehensively and in your code page of your current language (I believe), because these error messages were saved in OEM by HBMK2 (STD out) in my case in CP850.
Screen105.png (61.46 KiB) Viewed 3283 times
This caused the non-display of accents in the Portuguese language (which is my case). Since this application can be used in several countries, in several languages I had to find a way to use hb_Translate with the correct and not fixed CodePage, then be able to find a function in harbour.
For those who want to know about this go to: viewtopic.php?f=7&t=5142
<Attached files were removed due is a newest version more ahead of this same topic>
Just to remind you, save ViewError at same folder/place that you had before.
If you have not tried this app yet ... you're missing out on a great opportunity to improve and streamline your builds. :roll:

A TIP: I usually put ViewError.exe in a folder called: HMGTools

Resizing window/control is handled in order to improve your visualization. :)

I hope you enjoy it !   :P

Re: ViewError - HMG building utility

Posted: Thu Mar 30, 2017 10:41 pm
by Pablo César
RPC wrote:
Thu Mar 30, 2017 8:10 pm
Viewerror doesn't produce any error as such but the small window at start of compiling just disappears and nothing happens.
Even the programs which compiled without viewerror don't compile. I had to delete registry key so that I could use IDE to compile programs.
Hi Rajeev,

I'm trying to figure out what happened.
Based on the short informations you gave me, I can deduce that you had installed the ViewError, formatted your hard disc and run it in another place, another folder was stored, then for the app is at a new place that it had been installed. Then the app recognized automactically but never has been setted a new location as default.

You said you had to go into the Windows registry and delete the key. What key ?

I know you must have overlooked the source code. But if you pay more attention, you will see that the operation of the ViewError is not governed by REGISTER. It only works with environment variable.

That's why I say, if there were more details for me to understand better way I will find a solution. :oops:
Probably I do it better or I would instruct you to run the ViewError again and put it in the new place as default.
This requires administrator rights. It just to run it as administrator.

Anyway I will try to improve this app.

Re: ViewError - HMG building utility

Posted: Fri Mar 31, 2017 7:00 pm
by RPC
Hi Pablo
After formatting I downloaded in default-Downloads-folder and ran it from there.which was C:\Users\SPC\Downloads\ViewError (Exe)
When I started getting problems with it I deleted viewerror.ini file from the ViewError (Exe) still I got problems so I went to Key
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Environment\ViewError
and deleted Viewerror key there.
Only then was I able to use IDE.
I dont know what i did wrong.

Re: ViewError - HMG building utility

Posted: Fri Mar 31, 2017 8:50 pm
by Pablo César
Thank you Rajeev for returning.

You write so shortly and sometimes I need more info and probably it is a kind of cultural way to be synthesized...
(Maybe the lack of time pushes people to be like this) :|

It's difficult to understand what happen. I again deduce by risking to ask you:

By the way, in these times of compilation (very strange thing) did you configure the ViewError with the option of viewing the source codes by the Grid or your favorite editor? Was the favorite editor installed? Which would be ? Does it allow line pre-positioning parameters like Notepad++ ?

I've made some changes and other implementations that will certainly give more versatility. You could kindly (do not be in a hurry) to test this new version.
Screen158.png (56.3 KiB) Viewed 3310 times
  1. For error messages (not errors in PRG), other errors like WINDRES or "undefined reference", for example, can be displayed in EditBox that allows the selection of text to be copied to the clipboard.
  2. This EditBox allows for resizing.
  3. You can change fontsize, background and font colors, both for displaying error messages and for displaying Grid PRG.
  4. New parameters like: /REMOVE and /CONFIG have been added to allow uninstallation and change of configuration.
  5. SetRegValueAsAdmin and ShutDown (See comments) functions have been added to ensure change in REGISTRY.
    I take the opportunity to clarify that using ViewError does not enforce access to REGISTRY.
    Only at the time of setup is accessed to configure an environment variable.
  6. Uninstall process was improved.
  7. To install the application, it is still the same as always: when clicking the app through Windows Explorer or at the command line (without any parameters).
<Attached files was removed because there is a newest version more ahead of this topic>
Note: (This added later) For those who were already user of the ViewError app, i.e. for those who already had it installed: it is recommended to delete the ViewError.ini from the current folder. This will create the file with new properties.

With the all continous help (by testing/reporting) will certainly help me to improve this app. I have been using it a long time and find it very useful and hope it serves the same purpose to all of you. The idea is to speed up the compilation process by showing the error in the text editor itself. Of course, using it is optional but your feedback interests me a lot.

Re: ViewError - HMG building utility

Posted: Sat Apr 01, 2017 12:21 pm
by Pablo César
  • ShutDown. I want to explain the reason for using this procedure.
    When we create a fixed environment variable, not temporary, as it is in this case we can open one, two instances and as many as we want, the variable will always has the available value. But if we need to delete it or modify it, how to do with those instances already open and be able for updating variable in each one of it ? Therefore it is practical to request or force the boot of the equipment.
  • For example:
    1. Create an enviroment variable. (This video shows how to do:
    2. Lets say to open two instances of Prompt Command.
    3. In each Prompt window type: SET <Enter>
      Then you will see your variable that you have be created. Perfect upto now.
    4. Now you go again to system/environment variables a modify its value of same variable.
    5. Returning the two instances of Prompt, enter SET again.
      You will note that the variable it's still with the olf value.
      It's by this reason the system need to be booted.
  • In this case, when the application continues without the system being initialized, the same app behavior will persist because the variable is still in memory.
For this reason I have reinforced the messages so that the user is warned and that the installation or uninstallation procedure is finished.

Re: ViewError - HMG building utility

Posted: Sat Apr 01, 2017 2:00 pm
by Pablo César
Attached files on previous messages at viewtopic.php?p=50537#p50537 had been updated
due the FontSize of EditBox was not changing.

Now fixed and saves value too.

For me a good font size is 12. This value is upto 12.
Screen161.png (53.07 KiB) Viewed 3276 times
This window exits is by [Esc] keyboard.