On error...

Creative ideas/suggestions for HMG

Moderator: Rathinagiri

User avatar
esgici
Posts: 4543
Joined: Wed Jul 30, 2008 9:17 pm
DBs Used: DBF
Location: iskenderun / Turkiye
Contact:

Re: On error...

Post by esgici »

Hi Dilip

And, about SAVE command, please look at here.

Regards

--

Esgici
Viva INTERNATIONAL HMG :D
Dilip Patel
Posts: 31
Joined: Tue Aug 17, 2010 6:01 am

Re: On error...

Post by Dilip Patel »

Hi Esgici,
Thanks for the file layout descriptions and the save command description.
The memory file layout has helped. I am trying the display the variables from the saved memory file on disc and not from the internal memory as was the case. When the save command is issued a variable of more then 10 characters is truncated to ten characters in the saved memory file, therefore I will not be able to display the full variable description.
User avatar
esgici
Posts: 4543
Joined: Wed Jul 30, 2008 9:17 pm
DBs Used: DBF
Location: iskenderun / Turkiye
Contact:

Re: On error...

Post by esgici »

Hi Dilip
Dilip Patel wrote:...I am trying the display the variables from the saved memory file on disc and not from the internal memory as was the case. ....
Good 8-) , please continue; I do ;)

Do you meant "display values of variables from the saved..." :?:

Regards

--

Esgici
Viva INTERNATIONAL HMG :D
User avatar
esgici
Posts: 4543
Joined: Wed Jul 30, 2008 9:17 pm
DBs Used: DBF
Location: iskenderun / Turkiye
Contact:

Re: On error...

Post by esgici »

Hi Dilip

By the way, what do you think about "low-level" affairs in the our "template" .prg ?

I'm annoying :(

Again, by the way; I guess your and my time zones not different and this is too late for wok; didn't you feel tired yet ?

Regards

--

Esgici
Viva INTERNATIONAL HMG :D
Dilip Patel
Posts: 31
Joined: Tue Aug 17, 2010 6:01 am

Re: On error...

Post by Dilip Patel »

Hi Esgici,

No you are not annoying. Thank you for your interest. It just kept me going and at my age it is wonderfull. I had thought i would would just post the clipper program on this forum and some one would modify it for HMG.

Just tested the revised error program. I am now listing the truncated variables. Attached is the revised version of the program. Yes, it is late and I am now about to go and have some rest. I am a novice at HMG. Have written some small programs which I will post as samples in a couple of days. I am a bit lost when you are referring to the LOW LEVEL TEMPLET .prg?
Thanks Again,
Dilip
Attachments
tst03.rar
(807.11 KiB) Downloaded 330 times
User avatar
esgici
Posts: 4543
Joined: Wed Jul 30, 2008 9:17 pm
DBs Used: DBF
Location: iskenderun / Turkiye
Contact:

Re: On error...

Post by esgici »

Hi Dilip
Dilip Patel wrote: Just tested the revised error program. I am now listing the truncated variables. Attached is the revised version of the program. Yes, it is late and I am now about to go and have some rest. I am a novice at HMG. Have written some small programs which I will post as samples in a couple of days. I am a bit lost when you are referring to the LOW LEVEL TEMPLET .prg?
Very good :)

"Template" prg is ERRORSYS.PRG written by STEVE STRALEY; and "low-level affairs" are that FCREATE(), FWRITE(), FREAD() etc... ;)

Did you tried Numeric and Date variables ?

Good night :)

Regards

--

Esgici
Viva INTERNATIONAL HMG :D
Dilip Patel
Posts: 31
Joined: Tue Aug 17, 2010 6:01 am

Re: On error...

Post by Dilip Patel »

I have not tried the date and the numeric values from the memory files on disc. Will give it a try on monday. I used this template program around in 1992. As for the low level files it just required some reasearch and that was wonderfull. Also thank you for pointing out the sight where the memory file layout was obtained. It was extremely helpfull. The original template programs had some statements that were incorrect and the result of which was not used in the program. That caused a lot of confusion. Once I obtained the layout quite a bit of the problems were solved. Thank you once again.
Regards,
Dilip
User avatar
esgici
Posts: 4543
Joined: Wed Jul 30, 2008 9:17 pm
DBs Used: DBF
Location: iskenderun / Turkiye
Contact:

Re: On error...

Post by esgici »

Hi Dilip
Dilip Patel wrote: No you are not annoying. Thank you for your interest. It just kept me going and at my age it is wonderfull. I had thought i would would just post the clipper program on this forum and some one would modify it for HMG.
First, please dont "edit" your post after sent; I can't follow :(

"Annoying" is to that "low-level affairs" ;)

What is your "wonderful" age ( I can't see in your profile ) ? ; it's too big or too little ?

Please don't care about HMG programming; you are a good Clipper programmer and difference between Clipper and HMG is only difference between DOS and Windows. Fortunately, our master Roberto produced this wonderful tool. As easy to learn and use as Clipper, as powerful as Clipper and as capable as Clipper. Difference of HMG is difference of Windows programming. Again fortunately too many samples we have and can't be any pretext for don't learn.

For avoiding truncation on variable name, IMHO a way, instead of obtain value of variable by macro substitution ( with the macro operator : & ); may be reading this value from .mem file.

Please continue, I do ;)

Regards

--

Esgici
Last edited by esgici on Sun Jul 29, 2012 10:45 pm, edited 1 time in total.
Viva INTERNATIONAL HMG :D
User avatar
esgici
Posts: 4543
Joined: Wed Jul 30, 2008 9:17 pm
DBs Used: DBF
Location: iskenderun / Turkiye
Contact:

Re: On error...

Post by esgici »

Hi Dilip
Dilip Patel wrote:...I used this template program around in 1992. ...
hmm, 1992 ... I guess our ages are a little close to each other ;)

Do you have e-version of other .prg in that ( may be other ) books ?

Regards

--

Esgici
Viva INTERNATIONAL HMG :D
Dilip Patel
Posts: 31
Joined: Tue Aug 17, 2010 6:01 am

Re: On error...

Post by Dilip Patel »

Hi Esgici,
I am 61 years old. The book i had donated to a youngster in 2001. What a pity. My Clipper skills i learnt from a book by Marian Liskin and from Steve Straley. The Steven Straley book was very execptional.
The truncation of the variable name is as a result of Harbour writing only 10 characters of the variable name in the saved memory file. The original routine read the stored variable from the memory file and with macro substitution obtained the results for printing. I have no other way of knowing or obtaining the stored variables in memory. The program was crashing because when the truncated memory variable was referenced, it could not find it.
I am learning how to post, will not re-edit a post in the future.
By the way, I am using a program developed using HMG for the last 5 months for my wifes home business. Thanks to HMG and Harbour to date no crashes. Wonderfull sets of programs. Left the Clipper community in 2001. Now I am back and I am happy.
Tonight I will post the programs I have developed (with sources). I must thank Sudeep, for it was his samples of the EXPENSE programs that got me interested and started in the usage of HMG and Harbour.
Regards,
Dilip
Post Reply