Excel Protected Data Source For Power Query - excel

I am exporting reports from QuickBooks Online as Excel attachments via email. I am then using Microsoft Flow to save the attachments to Sharepoint. Then, I am using those Excel files stored in Sharepoint as the data source for my reporting. I have one report (out of 7) that's coming through with a protected view, which is causing it to look like this in Power Query:
The actual Excel file looks like this when I open it:
From what I can deduce, this is because there's some level of protection on the Excel file. However, the other theory I have is because each of the cells have "=" before the numeric value. In other words, the first cell has "=750" instead of just "750". If I go into Sharepoint, open the file in Excel Online, remove the "=" in just that one cell, and refresh Power Query, then the amounts show up in the editor as expected.
Is there any way to deal with this in Power Query? Thanks in advance for your help.

Related

Power Query to open XML file formatted as Excel would open it

I have an XML file generated by EasyPower (electrical software). If I open the file in Excel it comes up as a series of formatted sheets like the image below. It appears this way without any prompts or dialogs.
I’m creating a Power Query routine that can extract the data from the sheets. Unfortunately when I use the Power Query wizard to select the XML file as a source, it doesn’t see the data as sheets, but rather a table with columns of Tables, seemingly an infinite number of levels deep. Digging through them I’m unable to clearly see the data. This is not a very good approach.
A work-around is for me to manually open the XML file with Excel and save it as XLSX, then it’s easy to work with the data in Power Query. I know a VBA script could be used to this but my question is, is there a way for Power Query to open an XML file and interpret the layout the same way that Excel does? This way would allow my script to also work within Power BI.
Edit: A sample file has been requested. This link will provide a very simple example containing two worksheets when opened in Excel. EasyPower_Test_Schedule.xml

Can I use a database built in SharePoint for data validation in an Excel spreadsheet?

I have a dataset that is being built in SharePoint that contains data including job codes, dates, descriptions, and other variables. I want to limit data entry in an Excel spreadsheet to only values in the SharePoint dataset. Possible? Well I know it's possible.. but HOW?!
You can export the SharePoint list into Excel. Click the Export to Excel command in the SharePoint list.
That will download or open a query file. If it only downloads, double click to open the file with Excel. Enable data connections when prompted.
Confirm that the data should be loaded into a new workbook, or, if you already have a prepared file open, use that and load the data into a new worksheet.
When you do that, a dynamic data connection is created. This data connection can be configured to refresh each time the workbook is opened. Data Ribbon > Queries & Connections > Right click the query in the query panel > Properties
You can then use the query data for the data validation.

Excel refresh fails on OneDrive for Business

My excel workbook has the following solution implemented:
The solutions is to loop through multiple excel files on OneDrive into one. The excel has the following sheets:
Sheet1(Home Page): This has a table with a Key-Value pair. Key stands for the department and value is the path of the files on SharePoint
Sheet2: This sheet has the data from all the files mentioned in the Sheet1.
This is implemented using the power query. I’ve created a custom function in Power query to loop through the files in the table mentioned above and get the data.
The function to pull the data looks like this:
This solution works perfectly when I refresh from my excel desktop.
When I place the file on one drive and open the same excel on the browser and hit refresh connection I see the following error:
Inputs on troubleshooting this error will be appreciated.
Excel Online does not support Power Query. You can have a data model and use pivot tables based on that data model in Excel Online, but you cannot refresh Power Queries or external data sources when you open the file in the browser.

Excel PowerPivot - change data source type

I have an Excel 2016 with 30 graphs based on PowerPivot. PowerPivot fetches the data from another Excel sheet, but I want it to get the data from a SQL server table instead.
How can I change the data source type in PowerPivot? I've tried looking in the Excel xml without any luck. Would be a lot of work re-creating all graphs over again just to switch data source
Thanks
Dennis
One suggestion I would make for the future, if all the users are using 2016 is to use Power Query which comes standard with that version of excel. In the Power Query loading data into Power Pivot scenario, all Power Pivot cares about is the column names. This means that the query can be changed between data source types without causing issues, as long as the same column names are changed.
As an example, I have one file that based on a parameter flag rips data out of a series of excel files on a shared network drive or Share Point. Both of which would be different data sources. The first opening a folder as the data source, then excel files listed within the folder. The other opening a share point list as its data source, then navigating though excel files.

Using a JIRA saved filter with REST API and Excel

I have a report that I need to update in Excel many times a day using statistics from JIRA. If I can import these directly with code I would save a lot of time and effort.
Is it possible to use a saved JIRA filter in conjunction with the REST API function to import the results to Excel using a VBA macro?
This is a solution does not use REST API, but it may work for you. This is a workaround I am using so far and it works:
Run the Filter in Jira
Export the result list into an excel file using the Export CSV file with the option current field (to avoid having unnecessary fields) and with the right button of mouse select: Open in a new window
Now you will see the URL associated with your filter in a new window of your browser. Your filter is represented by a Filter ID, therefore the query will be always the same.
Go to excel and use the URL as a hyperlink
Every time you click on the hyperlink it will download the file from Jira. You need to have a Jira open sesion in your browser.
Create a VBA marco that click on the hyperlink for downloading the file.
Use Power Query for example for loading the file from the download folder location into a worksheet. Power Query is a new excel feature. Power Query is an ETL tool integrated into excel for loading files and processing them.
The steps 6-7 automates the process. Run the Marco for downloading the file and refresh the content of your worksheet from Data Connection. You can have an additional macro that refreshes the content of the worksheet. It refreshes all pivot tables and the file connection for reading the file.
Hint: Use excel Table for keeping the information updated automatically when additional information is loaded into the worksheet. If you use pivot tables for presenting the data, use as data source an excel table instead of excel range.
It minimizes a lot the manual effort.
Here you can find a solution that uses REST API, the author provides the source code, but it is more complicated. If you need something simple, my solution may work for you.

Resources