×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

File created by the application is locked by some unknown user.

File created by the application is locked by some unknown user.

File created by the application is locked by some unknown user.

(OP)
The foxpro application that I use, on click of a list item in the menu creates a template file in a folder placed in the D:/Shortcuts/Sharedfolder/Template/B .. where in the properties of B folder the target is \\SERVER\BMar2006pf92014\TEMPLATES.

Please understand this.
This is the main folder that is the path to all the files one of my foxpro application uses

\\SERVER\BMar2006pf92014\TEMPLATES

The TEMPLATES folder of the folder BMar2006pf92014 ( application folder ) is then renamed to "B" in D:/Shortcuts/Sharedfolder/Templates/B.

What happens is, is that a .dbf file get created which is used as an template to input data into the fields as it is opened using LibreOffice, it is saved.. and when in the application an item in the menus is clicked that file goes back to \\SERVER\BMar2006pf92014 from where the data is given back to the application from whic further processing is been done.

( if I made myself clear upto this, I should get a pat on the back, if not I need to improve and have failed )

The problem is this for that past few months this all process was working flawlessly ! today what happens is weird... when the file is being created and comes to D:/Shortcuts/Sharedfolder/Template/B, the LibreOffice file does not gets open as original file, what it means I cannot edit this file I cannot delete this file, I cannot save this file, only I can do is Open a copy -> save it to desktop -> and never use it again, as only the files that are in the folder D:/Shortcuts/Sharedfolder/Template/B goes back to \\SERVER\BMar2006pf92014 and get used.

I contacted the Microsoft Advisors, hoping this would be some issue with permissions, 2-3hrs went in, and no solutions was reached. As even I think it is related with some foxpro...

What weird is that, the same process was running fine since 7-8 months and on other pc's it still runs the way it should be, but on the SERVER pc it is not running as it is supposed to be.



Please help if anyone has any idea.

RE: File created by the application is locked by some unknown user.

This error comes from Libre Office, doesn't it?

The only thing you could be doing wrong in VFP is after you create this DBF, keep it open. Files you create as new dbfs, no matter if fox2.x or part of a dbc, are open exclusive to the creating process. To let other processes use the file, you have to close it.

So in any PRG doing a CREATE TABLE, after its there, close it with USE or CLOSE ALL or CLOSE TABLES ALL. Perhaps if it's not a big problem even quit from the exe.

Bye, Olaf.

Olaf Doschke Software Engineering
https://www.doschke.name

RE: File created by the application is locked by some unknown user.

Well,

and obviously, since it worked for a long time, you usually do close dbfs you create.
But then is it LibreOffice, that opens a dbf exclusively again?

You can use the Server's Computer Management console to find out which files are used by whom, so log in to that server open computer management, drill down system->shared folders->open files and you see which user has the file open. Note: This will only show file usage from clients opening files in your shares via the LAN.

Bye, Olaf.

Olaf Doschke Software Engineering
https://www.doschke.name

RE: File created by the application is locked by some unknown user.

Could it be a timing problem?
Maybe do a FLUSH FORCE in VFP after closing the table?
Eventually also Sleep a bit before starting Libre Office?

RE: File created by the application is locked by some unknown user.

What are you doing in code?

By the way, I would also be surprised if any software like an office suite running with normal privileges could tell you which other user has a file handle. This is something you only find out at the fileserver and with administrative privileges. So I wonder why LibreOffice actually has this message that is formatted as if it could also display a user name in this separete line.

Since usually only your application and LibreOffice (started by your application?) are involved the user would be your application user. I'd assume you're stepping on your own foot anyway. But one other common "User" would be system or some system account running antivirus. If you use that share only for your dbfs, it would be acceptable to exclude the share from scanning. Because right after the file is created and you close it would be a time I'd also expect antivirus to open the file and check it. And if you start LibreOffice at the same time and pass in the file to open in LibreOffice, it would be no wonder this file has too many users and processes interested in it at the same time.

And as antivirus software updates automatically, usually just with new virus definitions (data for what to scan), behavior changes are rare, but there always is some first time. Such a change in behavior can start anytime through updates of Windows, antivir, and LibreOffice. And what else not, an automatic live backup like time machine saving all files when they come or change.

Bye, Olaf.

Olaf Doschke Software Engineering
https://www.doschke.name

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close