Exception thrown by code stage : Access Denined

Shiva

New Member
Hi All,

When I am Trying to read data from excel using Code stage. It is throwing an exception Access Denied.

Could please some one help to resolve this issue.

Regards,
Shiva
 

Sachin_Kharmale

Active Member
Hi Shiva,
Probably you have not full access to excel file.


Cause
This issue may occur if the following conditions are true:

  • You try to open a file that is located in a redirected folder that has been set by Group Policy, or you try to save a file to a redirected folder that has been set by Group Policy.
  • The parent folder of the redirected folder does not have the Read Attributes permission set for you.
Resolution
To resolve this issue, set the permissions on the parent folder of the redirected folder as following
User Permissions
Enterprise administrators Full Control
Domain administrators Full Control
Authenticated users Traverse Folder / Execute File List Folder / Read Data, Read Attributes
 

Shiva

New Member
Hi Sachin,

Thanks for the replay and solution, but in my case Two Ms Excel was running in the task manager when i close those ms excel from task manager it working fine.
 

Sachin_Kharmale

Active Member
Hi Shiva ,

1.For reading excel file you have develop your own code in code stage?
2.Or you are using existing Blue Prism - MS Excel VBO to read data?
if yes elaborate more so we can understood the problem.
 

Shiva

New Member
Hi Sachin,
we have written a code stage to read hyper link from excel file
if excel.exc is opened in task manager it is throwing Access Denied error.
 

Sachin_Kharmale

Active Member
Probably the error due to the code written in code stage.
Check code if possible the code that you have written in code you can post here
Or handle exceptions properlly it will give you actual cause that will throw access denied error
 

himavantht

New Member
Shiva -
This issue happend because an other instance is already open in the background, so BP doesn't have to read or modify on the sheet. It is caused because of improper closing of excel instance. So if you kill the process in task manager it will be unlocked for operations.

Best practice- always close instance of excel once we perform read or write operations using blueprism. So instance will be killed peacefully causing no access related issues.

Thanks,
Himavanth
 
Top