![]() |
![]() |
|
|||||||
| Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
New Member
Join Date: Mar 2002
Location: SHERWIN WILLIAMS CO.`
Posts: 1
|
I have a programming problem and I am
stuck on finding the solution. I wrote code to assign a sequential alpha/number to an Excel Worksheet, which functions as an IDI form used at work to upload journal entries into our general ledger system. The code works fine as long as only one person at a time accesses the shared data file. When two persons access the file at the same time I get the Exel error message box to open file as "ReadOnly". What I need is a way to test the attribute of the file to determine if it is set to "ReadOnly". Then I could use a "Do Until ... Loop statement to test for this attribute value and have it close and reopen the file until the attribute is False. I have used the help function, but could not find code that I could use to solve this problem. Do you have any suggestions? 3/28/02 Mark, Yes, I have tried Sharing the Workbook, however, this creates the problem of duplicate IDI numbers being assigned as multiple users are accessing the same file before the first user has update the file with the last number used. I need to find a way to control access to the file to ensure that only one user at a time can access the file. _________________ DJPSHERWIN [ This Message was edited by: DJP01S on 2002-03-28 11:23 ] [ This Message was edited by: DJP01S on 2002-03-28 11:31 ] |
|
|
|
|
|
#2 |
|
MrExcel MVP
Join Date: Feb 2002
Location: Austin, Texas USA
Posts: 11,654
|
Have you considered Sharing (Tools | Share Workbook...) the workbook?
[ This Message was edited by: Mark W. on 2002-03-22 14:26 ] |
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|