Refering to a variable in 'Excel Application scope not working"

i am trying to read the “excelWorkbookName” from File explorer using ‘get full text’ activity, which is working, and then insert that into “Excel Application Scope” which is not. im not sure what i am doing wrong. here are a screenshot of my

  1. Sequence

Im very intrested to see what i am doing wrong as everything looks okay and no spelling mistakes or anything like that.

workBook.GetSheets(0) Reads the first sheet in the workbook

P.S fileName is the path where the excel file is located. i.e. “c\User…”

we can directly mention the file path of that excel in EXCEL APPLICATION SCOPE right
may i know why we do with get text activity
and even if we get from GET TEXT activity kindly check once with the value of variable filename like whether it has the right folder path

Cheers @Rowley101

Hi @Rowley101,

Read this topic :slight_smile:

You can process the 3 PDF in another way:

  1. use the var1=directory.getfiles(LocalFolder)
  2. use a foreach with for each item in var1 (Body -> action).
    this will action to all pdf found in the LocalFolder one by one

Hope this will help.


i am using the ‘get text’ Activity so that when there is a new file in the folder, everyday, it can read that text and use it in Excel application scope.
‘Filename’ is correct.
basically in excel scope the path should look like this:

and currently in the path it looks like:
fileName + excelWorkbookName + “.xlsx”
Where fileName: “C:\Users\lurowley\PatientRecords”
excelWorkbookName: “Dummy_Patients_20191008”

Arent you just missing a \ after the fileName variable?

Hi everyone,

i have solved it.
used an assign activity

fileName = String.Join("", Directory.GetFiles(“folderPath", “*.xlsx”, SearchOption.AllDirectories).OrderByDescending(Function(d) New FileInfo(d).CreationTime).Take(1) )

Thanks for the support

1 Like