I am essentially wanting Excel to return a variable from PowerShell and input it into an activeworkbook on a Sharepoint server. Is this possible? I am wanting to excecute everything from Excel, so when data is imputed, it will initiate the PowerShell query, and when it obtains the information, I want it to dump the results into the Active Workbook that I am in. I have attempted to search via the internet, but really could only find information on creating new workbooks. Would love some insight, or best resource on how to accomplish my goal.
So… if you want all the code to run in Excel, you’ll be running Visual Basic for Applications (VBA), which is all Excel supports in terms of programming languages. VBA could probably launch a PowerShell instance to do something for you, and probably capture its output, but what you do with that will still be a VBA question since you’re executing in Excel.
VBA’s pretty old, and I’m not sure where to point you in terms of resources for connecting to SharePoint, or if it’s even feasible.
Thank you guys for your wisdom. Ideally I would like to remove Excel from the equation in it’s entirety, but it is the easiest way to grant access for the users that would be updating data for the query.