Many thanks for your excellent function TheRambler. I have tested it for all the relevant dates in our production calendar for 2004, 2005, and 2006 and all weeknumbers are correct!
I spent ages trying to find a modified ISO function that worked, and didn't find your source! Once again, thanks...
I need to calculate week numbers. We have a production week that starts on Sunday. This means that we use ISO 8601 week numbers offset by one day. In 2004 and 2005, this means that Sunday 26 Dec 2004 is the first day of week 53, and Saturday 1 Jan 2005 is the last day of week 53. Sunday 2 Jan...
Hi Rick
No, I'm not using Genscrnx, just the built in FPD26 screen builder. But your comment re temp files has made me think - it might be something to do with file permissions. I'll check this out. I assume you mean that the screen builder creates some temporary files as part of the generate...
I use an excellent third party program called Dosprint. This allos me to redirect all printer output to a shared spooler folder as text files. Then each network user has a copy of Dosprint installed that can print the text files to any Windows printer. This gave my ancient FPD2.6 app a new lease...
When I try to generate the spr file from my screen code, I get a "file access denied" error message and the file is not generated. If I build a complete new app, the spr is regenerated correctly.
This happens if I delete the spr file first, or leave the old version.
This has only been...
Sorry, should have clarified. I would like no border or title as Mike suggests, but also would like non rectangular display, e.g. round or tool-tip shaped "form" into which I can put messages from my running app, which doesn't have to be visible i.e. might be running in the background. I believe...
In a VFP project which has screen=off and 1 top level form, is it possible to load and display an image file (.bmp,.jpg etc.) on the Windows desktop? I found some excellent code on Foxite to load and display image files on a VFP form, but it does not work on the win desktop. I wanted to put...
My Foxpro 2.6a for DOS application with around 30 concurrent users was running on Windows 2000 server with XP workstations and was rather slow. Migrated the application and data to a new Linux server and used Dosemu and putty for the user terminals. There was a vast improvement in speed and...
I've just tested ThuVan's method of creating a single replace (or blank fields) statement, and it is much quicker - < 10 seconds to replace 1011 records from 38,294.
This was the routine:
_COMM = "BLANK FIELDS "
FOR x=32 to 242
IF x <> 33 AND x <> 193 && Do not clear field 33 or...
I've now tested this, the biggest improvement is with the use of BLANK FIELDS (FIELD(x)).
This is the routine now:
goto mStartrec
SCAN REST FOR Invlines.Date <= Menddate
FOR x=32 to 242
IF x <> 33 AND x <> 193 && Do not clear field 33 or 193...
I can see the logic in saying that a single replace statement operating on many fields should be quicker - but won't I run into the problem of statement length? Surely I will exceed the maximum number of characters with over two hundred field names in the statement?
Thanks, all, for the suggestions, will try out and benchmark. I think a combination of SCAN REST...ENDSCAN, BLANK FIELDS, and less calls to the progress bar will be the fastest way.
Thanks all - I think the use of SCAN REST and less calls to the progress bar will probably be the best improvement. I'll give it a try tomorrow and let you know.
This originally posted in FPD area, but I use the same routine in VFP 7 apps.
I have a 40,000 record Foxpro 2.6 table. It has 244 fields and is 67Mb in size. I want to selectively clear the values in about 200 fields in 2000 records conditional on a date range. My code at present looks like...
I have a 40,000 record Foxpro 2.6 table. It has 244 fields and is 67Mb in size. I want to selectively clear the values in about 200 fields in 2000 records conditional on a date range. My code at present looks like this:
goto mStartrec && The first matching line is already located...
Thanks Mike, that would do the trick, although I imagine changing the class for each column after using the builder (which I use a lot) would take as long as sticking 'do drilldown' in each doubleclick method. Shame there isn't a row object with its own doubleclick method!
I wish to allow the user to double click on a grid row to show linked records in another table to a key field in the grid's table. At the moment I have a separate command button on the grid form that calls the drill down procedure, but to double click on the actual row would be simpler. The...
When I run my app from the project manager, the view, toolbars menu item is greyed out so I can't open the report designer or report controls toolbars. The standard toolbar is displayed correctly. What is going on?
What is the best way to store time values and do calculations on them? Obviously datetime is best storage type, but can I use just the time portion and do time math, i.e. subtract start time from end time etc. and get hours/minutes?
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.