Running wine script in xscreensaver

Questions about Wine on Linux
Locked
mishignu
Newbie
Newbie
Posts: 1
Joined: Thu Feb 10, 2022 3:24 am

Running wine script in xscreensaver

Post by mishignu »

I'm trying to run an old Windows screensaver from 3Planesoft, which I have successfully installed with PlayOnLinux and can run manually through terminal, but would like to set it to run with xscreensaver which returns the following from Wine when it tries to launch:

Code: Select all

Application could not be started, or no application associated with the specified file. ShellExecuteEx failed: invalid name.
It will, sometimes, show the 3Planesoft splash screen for a fraction of a second before that message appears, but usually goes straight to the error. I used the following script line in xscreensaver:

Code: Select all

wine "/home/misha/PlayOnLinux's virtual drives/Nautilus/drive_c/Program Files/Nautilus 3D Screensaver/Nautilus 3D Screensaver.exe"
Sometimes after moving the mouse to turn off the screensaver (error msg) the screensaver will actually load 30 seconds later, sometimes it won't load until I've moved the mouse to turn it off and then hit the settings button, and sometimes it won't turn on at all.. but it always displays that error.

I created a .desktop application file to launch it and pinned it to favorites on the dock, with no issues when using the favorites button, but I want to set it like a regular screensaver to automatically turn on after a set idle period without manually turning it on each time. It must launch the .exe rather than the .scr file, it's a paid product and running the .scr directly only displays the trial version. This is the .desktop file I created, which does not display any errors and launches perfectly, but fails when using the same path from the Exec= line in xscreensaver:

Code: Select all

[Desktop Entry]
Type=Application
Encoding=UTF-8
Name=Nautilus Screensaver
Comment=Nautilus Screensaver for Windows
Exec=wine "/home/misha/PlayOnLinux's virtual drives/Nautilus/drive_c/Program Files/Nautilus 3D Screensaver/Nautilus 3D Screensaver.exe"
Icon=ssaver.png
Terminal=false
If I point xscreensaver to /usr/share/applications/Nautilus 3D.desktop I get "no such file or directory" error from xscreensaver rather than Wine.
User avatar
JoseskVolpe
Level 4
Level 4
Posts: 124
Joined: Sat Sep 04, 2021 9:35 pm

Re: Running wine script in xscreensaver

Post by JoseskVolpe »

I'm not sure that would work, but i think ' and spaces might be what's preventing it to work
I'm not sure, i'm saying that because i remember having the same issue managing my shortcuts and i made them work after i moved their paths without any use of spaces
invisible kid
Level 5
Level 5
Posts: 368
Joined: Tue Dec 24, 2019 3:23 pm

Re: Running wine script in xscreensaver

Post by invisible kid »

I agree with previous poster about spaces and apostrophes being tricky areas. I did do an experiment and was able to launch:

Code: Select all

wine "/home/username/.wine/drive_c/temp's file area/sol.exe"
So that part seems to be okay.
Hopefully it's just a case of a typo, or a mismatched folder name or something. Like you've already done, you have to track down what it's looking for and where. Sometimes something isn't there that should be, other times it's a wrong location in a launch command. It could be some unique weirdness, but I hope not! Good luck!
Locked