Jump to content

File access restrictions?


mike5

Recommended Posts

Hi all.

I know it's not strictly scripting related, but yesterday I was working with a script which tried to create a Control VI from a template. The script worked well in my development project, but as soon as I copied that script to appropriate location for the "right click menu", I started getting "file not found". The template file was next to my "script" VI.

Does anyone have any ideas?

Thank you and best regards, Mike

Link to comment

If you're getting a file not found errors, it's usually because of the way relative paths are built. The easiest thing to do is to display that path where LV expects to find the file. This should help in determining why it's pointing at a location other than where the file is.

Link to comment

If you're getting a file not found errors, it's usually because of the way relative paths are built. The easiest thing to do is to display that path where LV expects to find the file. This should help in determining why it's pointing at a location other than where the file is.

Actually in the error I get the absolute path, and it's pointing exactly at the file I'm interested in.

Br, Mike

Link to comment

Does this only happen in the "Program Files (x86)" directory?

Was this file created newly?

This is a long shot, but maybe it has something to do with access privileges and the way Windows virtualizes writes to directories that you should not write to?

Maybe for some reason, DIR shows the virtual directory content, but LV sees what's really there, because it used the wrong file API functions?

Can you see this file in Windows Explorer?

Can you see it when you log in as another user?

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.