Win32::OLE error on file open - perl

I am trying to open a .xlsm file using Win32::OLE from my webpage in perl on windows/apache server.
On researching for this issue, came across the following possible solutions:
Few had it resolved by setting their path to a absolute one. This did no work for me.
Setting permissions for the script to have permissions to access files on server. I am not sure how to go about this. However, I am authenticating my user via windows sspi and will have a userid. Will that user id be verified for file access on Win32::OLE ?
However, I am able to open the file using a File Handle. I have read/written using file handles to files on this server location from my webpage earlier. Is the win32::OLE permissions different from that??
The error is :
Microsoft Excel cannot access the file 'C:\test.xlsm'. There are several
possible reasons:
• The file name or path does not exist.
• The file is being used by another program.
• The workbook you are trying to save has the same name as a currently open
workbook.
Win32::OLE(0.1709) error 0x800a03ec
in METHOD/PROPERTYGET "Open"
Appreciate any inputs.

OK, Finally got rid of the error after several attempts at modifying permissions and running apache as a separate user with all required privileges with no avail, by creating a profile folder for Desktop under
C:\Windows\SysWOW64\config\systemprofile\Desktop
Found this solutions in msdn forum http://social.msdn.microsoft.com/Forums/en-US/innovateonoffice/thread/b81a3c4e-62db-488b-af06-44421818ef91?prof=required
Hope this will help someone using these modules in future

Related

Trying to import CSV file to Analysis Services Tabular project

I have Microsoft Office Professional Plus 2019 and Access database engine both 64-bit installed on my machine and was trying to import a CSV file to Analysis Services Tabular project. However keep getting the error message shown below.
"Failed to save modifications to the server. Error returned: 'OLE DB or ODBC error: The Microsoft Access database engine cannot open or write to the file 'BatchInfo.csv'. It is already opened exclusively by another user, or you need permission to view and write its data.; 3051."
Any help is appreciated please.
Either you or someone else has the file open. Sometimes you have to completely close out of the program that created the file, or the last program used to read, write, or save the file.
If it's something on your computer, you may be able to find what has it opened with the Process Explorer tool. Install it, and then use Find > Find Handle or DLL... and search on "BatchInfo.csv".

Problem reading cosmosDB files in VS code due to : in filename

I am storing integration logs in CosmosDB which have a timestamp in the filename including a ":" character. I'm not able to open the files in VS code because of this (and maybe the "." character as well). I found a github issue talking about this, but that issue is closed and I'm still not able to open the files. Need some guidance on what I can do to open this files from inside VS code. Yes, I could change the filename but I'd prefer just to make it work. I can open fine in the Azure Portal.
Example file name: 2019-09-04T14:38:35.308Z
Error message: "ENOENT:no such file or directory"
It seems this is a limitation based on allowable Windows filenames, so the option is either to rename the file or accept that I cannot read this files within VS Code and use Azure Storage Explorer instead.
I'm happy to accept a different answer if anyone out there has any other options!

VS Code is looking for files in C:\c:\ directory which does not exist, resulting in many problems with namespaces and modules in my project

I have a project opened in VS Code. The project folder is on my desktop. When in VS Code, I attempt to work on a file but get many problems in the 'PROBLEMS' tab. It says the file is in C:\c:\Users\Me\Desktop, but I don't have a C:\c:\ directory which I believe is the cause for all the problems. This prevents intellisense from working correctly. How can I fix this problem?
I've tried cloning the project into different directories but the same problem arises.
I've tried looking for the C:\c:\ directory but it does not exist.
When I click on one of the problems I get, 'Unable to open 'filename.fs': Unable to read file (Error: File not found (c:\c:\Users\Me\Desktop\projectfolder\src\Client\foldername\filename.fs))'
Problems that appear are namespace or module 'Elmish' is not defined. This happens for everyt namespace and module in my project.
'Unable to open 'filename.fs': Unable to read file (Error: File not found (c:\c:\Users\Me\Desktop\projectfolder\src\Client\foldername\filename.fs))'
This is a known issue and a fix is on the way:
bug report
fix
In the future please submit bug reports to the extension repository directly, as we do not track stackoverflow and this site is not meant for technical support.

Group policy to make Chrome open files automatically after download

I am in the process of updating our currently existing Chrome distribution so that when a user downloads a .pdf file, the file is opened automatically.
As a first step, I was able to prevent Chrome from opening the pdf in its internal pdf viewer and could do a registry entry by using AlwaysOpenPdfExternally. This way it was downloading the file immediately and not opening it in the Chrome viewer.
I'd like to use Adobe to view the file automatically after download.
Unfortunately I was not able to find a registry entry. Nor was I able to find a GPO entry to be changed for Chrome.
I had found the following PowerShell script to be started upon logon of the user. However, testing it did not give me the result I was looking for.
The given entry extensions_to_open was not existing even after starting the script.
The current version of Chrome used is 66.255.
I would be happy for any help.
Edit: I am able to get the file to be opened automatically by inserting the given line here:
Is there any way to programatically force "Always open files of this type" for a specific file type in Chrome?
however, I am unsure of how to distribute the line of code into every PC in my network.
Edit: Chrome offers Group Policy Templates which should be importet into the active directory of your Windows Server. Once imported into your GPO, Chrome offers the setting: "Always open Pdf files externally". Once you check this feature, file should not automatically open in the internal PDF viewer.
See second edit: import the latest group policy templates into the GPO (will be stored on the active directory). After that, go into the GPO policies for "Google Chrome" and check the feature "Always open PDF files externally".

php_warning on installing ext

I want to intstall the ext "my_redirects". On my local machine it does what it should. But now, on the live site, i got this error:
1: PHP Warning: file_get_contents(/kunden/homepages/28/d574274134/htdocs/update7/typo3/sysext/core/Resources/Private/Sql/Cache/Backend/Typo3DatabaseBackendCache.sql): failed to open stream: No such file or directory in /homepages/28/d574274134/htdocs/update7/typo3_src-7.6.14/typo3/sysext/core/Classes/Cache/Backend/Typo3DatabaseBackend.php line 441
I got a hint to delete the typo3temp/autoload/ files. Then the installation works, but if i after that go into the install tool, i get this error again. Can someone give a hint?
This file is part of the core and must exist. Look into the src-tar/zip file. Maybe the file wasn't transferred to the server.
I don't think it's an autoload issue, because the .sql file is missing, not the PHP class.
Please verify that the sql file does exist. If it's missing, check the hash of your downloaded TYPO3 core. Make sure you compare the correct path on the server.
But I guess you got an access restriction. Maybe bad ownhership of that .sql file? Perhaps you ran into some security problems with file_get_contents() and at least sql files? So please also check your security settings.