Page 2 of 4

Re: Save and restore arrays

Posted: Fri Feb 14, 2020 3:34 pm
by AUGE_OHR
hi,

ok, understand.

have made a Sample with FieldWideStatic and Show()/Hide() Form with Checkbox "when running" how it can be used
FieldWideStatic.ZIP
(1.3 KiB) Downloaded 114 times

Re: Save and restore arrays

Posted: Fri Feb 14, 2020 3:45 pm
by AUGE_OHR
RPC wrote: Fri Feb 14, 2020 2:44 pm Perhaps you can also help with "save" bitmap image problem I have mentioned above.
try other Bitmap ... something does not work but my Bitmap (16x16) work as Resource
Bad_BMP.jpg
Bad_BMP.jpg (14.09 KiB) Viewed 2197 times

Re: Save and restore arrays

Posted: Fri Feb 14, 2020 6:05 pm
by RPC
Hi Jimmy
Your program works till we are in the program when we leave the program and run it again it does not maintain the same state of check boxes.
The state is in fact not saved(to disk for restoration later) in your program.
Thanks though for your efforts.

Re: Save and restore arrays

Posted: Fri Feb 14, 2020 6:07 pm
by RPC
AUGE_OHR wrote: Fri Feb 14, 2020 3:45 pm try other Bitmap ... something does not work but my Bitmap (16x16) work as Resource
This works. I changed my bitmap image size to 16x16 and now it shows on the button
Thanks for the help.

Re: Save and restore arrays

Posted: Sat Feb 15, 2020 4:39 pm
by edk
Hi RPC.
Recently, I worked on something similar, except that I needed to be able to set 27 checkboxes for each record. I didn't want to do 27 fields for each record, so I was looking for a solution to "encode" them in one field. Since I don't expect more checkboxes than 32, I used a 32-bit number to encode their state, which I then encoded into a binary string. And so to encode 32 checkboxes, a string of 4 characters is enough.

My sample:
GRID_25.7z
(3.07 KiB) Downloaded 139 times
To edit checkboxes just press Enter or doubleclick on ">> Show <<" fields.

Edward.

Re: Save and restore arrays

Posted: Wed Feb 19, 2020 11:41 am
by RPC
Hi Edward
Thanks for your reply.
Sorry I got busy with my work and did not check the forum earlier so could not reply.
My program uses about 50 check boxes but not any tables(dbfs) so my requirement was much simple. Any way I have learnt something new from your demo. I will keep it in mind and use it future whenever required.

I was about to PM about something you guided and helped me immensely.

If you remember you helped me in downloading files from the net by providing necessary code for http and oSoap. I am very much thankful to you for that.

But now I am stuck with another problem. I need to download an old file from net. I can download the file when enter/paste the address in the browser but get error no 403 forbidden when I try to download it through program you have provided. I am enclosing the program. I can download files from 1 jan 2016 on wards but not prior to that for eg 19 feb 2015.

Please have a look.

Many thanks

Re: Save and restore arrays

Posted: Wed Feb 19, 2020 2:20 pm
by edk
Hi. I don't promise, but I will try to look at your problem by the end of the week.

Re: Save and restore arrays

Posted: Wed Feb 19, 2020 6:12 pm
by RPC
edk wrote: Wed Feb 19, 2020 2:20 pm Hi. I don't promise, but I will try to look at your problem by the end of the week.
Hi Edward
Please take your time.
I will wait.
Many thanks

Re: Save and restore arrays

Posted: Thu Feb 20, 2020 9:49 am
by edk
RPC wrote: Wed Feb 19, 2020 11:41 am But now I am stuck with another problem. I need to download an old file from net. I can download the file when enter/paste the address in the browser but get error no 403 forbidden when I try to download it through program you have provided. I am enclosing the program. I can download files from 1 jan 2016 on wards but not prior to that for eg 19 feb 2015.

Please have a look.

Many thanks
Hi RPC.
I checked quickly, but the link you generate also doesn't have access to the page from a web browser. Check the correctness of the links before 01/01/2016.
Link generated by your app: https://www1.nseindia.com/content/histo ... av.csv.zip
Bez tytułu.png
Bez tytułu.png (20.55 KiB) Viewed 1992 times

Re: Save and restore arrays

Posted: Thu Feb 20, 2020 10:37 am
by RPC
Hi Edward
You are right. I am getting the same message for 17 dec 2015. But I can download for 19 feb 2015 :?
Further when I download from the website at
https://www1.nseindia.com/products/cont ... eve_eq.htm
with Select Report as "Bhavcopy"
Date 17-12-2015
it downloads(in two formats csv and dbf) and provides links, when I hover over the link I can see the download link as
https://www1.nseindia.com/content/histo ... av.csv.zip
when I click the link the file downloads but again when I copy paste the link in browser I get the same message of Access denied.

In fact I can download this way from 3 nov 1994 on wards.

Please check
Thanks