While running the process -Read Range - ConfigFileName: The workbook does not exist

image
Please help me to solve this issue. I double-checked the config.xlsx file. The same project is running in my local folder.

Hi @K_K,

Since it is working in the dev machine, i would suggest you some options:

  1. Check if you have publish the same version that you are running in the dev machine.
  2. Try to update (or downgrade) the excel package, if you are using it.
  3. Delete the activity that it is not working, close studio, open it again and use drag a new acitivity.
  4. Try to use “Read Range” activity that is under “System → File → Workbook”

image

Let me know if any of these helped u.

Regards,

Hi,

How did you write path at Workbook path property?
If we run process from not Studio but nupkg, the project is extracted under %USERPROFILE%.nuge\packages. So if we use relative path, might not be able to find it.

Regards,

1 Like

Hi,
Thank you for sharing you ideas. I tried all 4 options still its not working.

Hi @K_K ,

Could you try adding a check to see whether the file exists or not before reading it?

File.Exists(filePath)

If its false, then you can slowly backtrack with a Directory.Exists() as well, to see which folder is not present.

Kind Regards,
Ashwin A.K

Hi Yoichi,
Thank you I solved it by using a relative path.

Hi,

How to give a relative path for .exe Application? This is my config sheet.

Hi,

I guess you run the process by another user (not PaulID) then it fails, right?
If so, it’s better to use environment variable as the following.

First set EdiUrl as the following in config file

%USERPROFILE%\AppData\Roaming\xxxxxxx

Then get the value from config and replace %USERPROFILE% to actual environment variable like…

Config("EdiUrl").Replace("%USERPROFILE%",System.Environment.GetEnvironmentVariable("USERPROFILE"))

Hope this help you.

Regards,

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.