STRU - Lists and modifies the structure of the dbfs files

You can share your experience with HMG. Share with some screenshots/project details so that others will also be benefited.

Moderator: Rathinagiri

User avatar
IMATECH
Posts: 168
Joined: Sun May 27, 2012 9:33 pm
Location: Brazil: Goiânia-GO.

Re: STRU - Lists and modifies the structure of the dbfs file

Post by IMATECH » Fri Oct 12, 2012 5:47 pm

Hi Esgici !



Then it is only your opinion ( Nothing started from Harbour Management Team )

In respect to your person I will finish any reply to your posts ( here only )



Regards
M., Ronaldo

By: IMATECH

Imation Tecnologia

User avatar
esgici
Posts: 4460
Joined: Wed Jul 30, 2008 9:17 pm
DBs Used: DBF
Location: iskenderun / Turkiye
Has thanked: 336 times
Been thanked: 103 times
Contact:

Post by esgici » Fri Oct 12, 2012 6:23 pm

Chacal.GO wrote:Hi Esgici !
Then it is only your opinion ( Nothing started from Harbour Management Team )
In respect to your person I will finish any reply to your posts ( here only )
Regards
Do you understand English ?

Does I said anything different ?

What is meaning of only I write one "H" opinion :?:
Viva INTERNATIONAL HMG :D

User avatar
Pablo César
Posts: 4059
Joined: Wed Sep 08, 2010 1:18 pm
Location: Curitiba - Brasil
Has thanked: 100 times
Been thanked: 179 times

Post by Pablo César » Sat Nov 24, 2012 5:32 am

Pablo César wrote:Mr. Grigory, now with your example I noted your indication it is for fixed color in all rows. But I needing to change color according a existing file at each row. So its could change color according each row in two diferent situations. Please see in my code source at line 1979.
Now I got It but with one particular restriction. HighLighted_Row's Color can be changed as Mr. Grigory indicated, but Grid MUST be in CELLNAVIGATION to .T.

Also very important to be mentioned: colors must be defined as CONSTANTs otherwise can not applied as simple ARRAY.

In blue color when is normal itens without any process:
Image

In rede color when there is a process vinculated with each field. Just to call attention of users:
Image

I would also like to change FONTCOLOR of button "Processos"... but still not found the way... :(

Thanks, Grigory !
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein

User avatar
Pablo César
Posts: 4059
Joined: Wed Sep 08, 2010 1:18 pm
Location: Curitiba - Brasil
Has thanked: 100 times
Been thanked: 179 times

Post by Pablo César » Sat Nov 24, 2012 6:54 am

New Release 4.2 with grig highlighted color changing by condition.

<Attached file removed, see last message with new release>
Last edited by Pablo César on Sat May 18, 2013 4:20 pm, edited 1 time in total.
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein

User avatar
Pablo César
Posts: 4059
Joined: Wed Sep 08, 2010 1:18 pm
Location: Curitiba - Brasil
Has thanked: 100 times
Been thanked: 179 times

Post by Pablo César » Fri Feb 08, 2013 4:53 pm

SpecialFolder to which I refer are the folders like "C:\Documents and Settings\Pablo César\My Documents" etc.

In Stru I want to add one more option. The ContextMenu that works in Explorer. That is, by pointing and clicking with the right mouse button on a file dbf, can give one more option: Stru - List. Then the user can list the structure of dbf from within Explorer.

But today I noticed something very strange, if I have a file in dbf SpecialFolder, it does not open and gives error, aborting the program. So I started doing a series of tests to circumvent this problem. Do not know yet if it's for XP and not be for lack of rights as administrator. So the next step and attempts suppose cPath:="C:\Documents and Settings\ Pablo César\ My Documents\" :

1. I put If! File (cPath+CDBF) and even though the dbf file is there, he returns as nonexistent.
2. Funny thing, I think this is the subject of hackers ... hihi, he accepts the cPath as "C:\DOCUME~1\PABLOC~1\MEUSDO~1", ie short names in standard 8x3. Hence opens and read it normally. STRU also works in command line already positioned in the folder C:\Documents and Settings\Pablo César\My Documents.
3. Tried to get me ShortPathName and returns empty. That is, the system can not see the folder which in this case is a SpecialFolder.
4. I also tried to position myself within the folder in program execution. But nothing.
5. Neither IsDirectory() function, which always worked well.

Has anyone gone through this. From what I remember, as happened to many, but it was Clipper. And I always put Clipper into the way in short order and always worked in the same SpecialFolders. Now the user can select the file by GetFile if he select a dbf which is within the My Documents will not work. And I do not think I can copy this folder into another dbf, because there is recognized.

Can anyone give me a light?
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein

User avatar
esgici
Posts: 4460
Joined: Wed Jul 30, 2008 9:17 pm
DBs Used: DBF
Location: iskenderun / Turkiye
Has thanked: 336 times
Been thanked: 103 times
Contact:

Post by esgici » Fri Feb 08, 2013 5:34 pm

Ola Pablo

"Special folders" is pretty complex subject :(

Has different visions between Win.Explorer and DOS (command) window.

I recently noticed that, there is "JUNCTION" term instead of DIR for "some" special folders in DOS box.

I don't know this will help you.

If you find a strong definition and usage rules for "special folders" please inform me too.

Saudação
Viva INTERNATIONAL HMG :D

User avatar
Pablo César
Posts: 4059
Joined: Wed Sep 08, 2010 1:18 pm
Location: Curitiba - Brasil
Has thanked: 100 times
Been thanked: 179 times

Post by Pablo César » Fri Feb 08, 2013 6:55 pm

Ohh thank you amigo Esgici, as always you are so kind !

I sent a MP to Dr. Soto, asking for any C code solution for these specialfolders cases.
Shall wait and I´ll revert to you.

Best regards
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein

User avatar
Pablo César
Posts: 4059
Joined: Wed Sep 08, 2010 1:18 pm
Location: Curitiba - Brasil
Has thanked: 100 times
Been thanked: 179 times

Post by Pablo César » Sat May 18, 2013 4:18 pm

The "Setup" option now has one more item that allows access to STRU by clicking on DBF in Window Explorer:
Screen71.PNG
Screen71.PNG (10.58 KiB) Viewed 1915 times
Also operates by Context-Menu of Window Explorer:
Screen72.PNG
Screen72.PNG (27.34 KiB) Viewed 1915 times
For operating systems with UAC, will have to be run as Administrator so that all changes in the Windows REGISTRY, take effect:
Image
With the coming of the HMG UNICODE mode, ensures the use of application in multi-languages​​. New implementations like as:

- Checks on SO is running as an administrator to change the LOG function of Windows.
- Check the build version of HMG, ensuring the implementation of new functions
- Verifies integrity of language files according the version performed
- Option STRU run in GUI mode from the command line

More tests will be needed to provide further more indications of possibles failures. I appreciate when you have this availability.

<Attached file removed, see last message with new release>

Important: Do not forget to delete the STRU.INI it now has new structure (cleaner), will also be necessary to replace the .LNG (language files) and be re-edited the ones have been converted to the UNICODE mode.
Last edited by Pablo César on Mon May 20, 2013 5:55 pm, edited 4 times in total.
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein

User avatar
Pablo César
Posts: 4059
Joined: Wed Sep 08, 2010 1:18 pm
Location: Curitiba - Brasil
Has thanked: 100 times
Been thanked: 179 times

Post by Pablo César » Sat May 18, 2013 4:42 pm

mol wrote:There is problem with Polish characters in console mode still.
It's because console mode uses CP-852 and graphics mode uses CP-1250.
Polish ascii codes are different in both codepages.
Only one way to resolve thi problem, is to declare different language files.
Hi Mr. Marek, I hope this problem have been solved with UNICODE mode at HMG. So please, could you re-edit POLISH.LNG in the new package of STRU.rar download and also please, delete Polish.TLg or rename it, just to make a test and see if is working properly. Could you do that for us please ?
Last edited by Pablo César on Sat May 18, 2013 9:51 pm, edited 1 time in total.
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein

User avatar
Pablo César
Posts: 4059
Joined: Wed Sep 08, 2010 1:18 pm
Location: Curitiba - Brasil
Has thanked: 100 times
Been thanked: 179 times

Post by Pablo César » Sat May 18, 2013 4:53 pm

Hi Dr. Soto, I have some questions regarding UNICODE adaptations in STRU.prg at function MakeLangArry, which is responsable to extract string from a language file in UNICODE format putting in ARRAY. Is presenting a diferences with first, last ans others elements of array. Please note in STRU.PRG at lines 2651 and 2653. For the last element it is needing to add an empty line at eof of language file.

It s strange these behaviour on different elementes of array (first one and last one). Probably depending to considere diferent EOF byte for recognition. What could be worng in my language files ?
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein

Post Reply