Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
TOO MANY FILES OPEN
Message
 
To
01/09/1998 10:22:51
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00131881
Message ID:
00131972
Views:
15
>I have a routine that RE-INDEX about 54 files. When I go to reindex the files i get to reindex all of them. In other machines I get a message saying: TOO MANY FILES OPEN.
>
>Any clue on this message?
>Thanks.

Hidy Sergio,

Consider the following suggestion. First, create a function to do an exclusive open on a table. The table should be in the current work area upon return. Have it return a logical value. If the function succeeds, do your re-indexing and then close the table. You could then write a procedure to do the work, closing the file when it's done. This should elminate the problem. Since you have a number of tables, pass an array containing the table names to it. I might look something like this:
PROCEDURE ReIndexTables

  LPARAMETER pa_tables
  
  EXTERNAL ARRAY pa_tables
  LOCAL lni, lnlast
  lnlast = ALEN(pa_tables, 1)
  FOR lni = 1 TO lnlast
    * ExclOpen is the name of 
    * the function to handle opening
    * the table
    IF ExclOpen(pa_tables[lni])
      REINDEX
      USE
    ENDIF
  ENDFOR
ENDPROC
hth,
George

Ubi caritas et amor, deus ibi est
Previous
Reply
Map
View

Click here to load this message in the networking platform