Creating a desktop launcher for Wine application

I have a script that I run to load my text editor (NoteTab Pro) which runs under Wine. Here is the script:

#!/bin/bash
wine "/home/lee/.wine/drive_c/Program Files/NoteTabPro7/NotePro.exe" "z:$(echo $1)" # | tr '/' '\\')"

To be honest, I have no idea what the second portion does but I know w/o it I can’t open a file in the program by right-clicking on it. However, using the second portion always produces the error, "Cannot open 'z:' because it's a folder". “z” is the virtual drive used by Wine. Pressing [ENTER] closes the error box and loads the program.

I need to either figure out the best way to write this script (I need to be able to open files with right-click) or add a carriage return to take care of the error message. Any ideas?

Hi LeeU,

Welcome to our forums.

The last part expects you to supply extra parameter althout the first pipe is commented which suppose to convert GNU/Linux slash “/” to windows “” . Perhaps this was meant to to open file directly etc.

Have you simply tried to change this script to:

#!/bin/bash
wine "/home/lee/.wine/drive_c/Program Files/NoteTabPro7/NotePro.exe"

Also make sure that the path to
/home/lee/.wine/drive_c/Program Files/NoteTabPro7/NotePro.exe
is correct.

Thanks. Good to be here.

Actually, the “#” is my fault. It should have been removed. I had copied it from ‘somewhere’.

And yes, this does work:

#!/bin/bash
wine "/home/lee/.wine/drive_c/Program Files/NoteTabPro7/NotePro.exe"

However, I can’t right click on a file in a file manager and open it. The link to “Open In NoteTab Pro” is there but it does nothing. The weird thing is that w/o the second part, or a portion of it, the right-click doesn’t work. ???

You will need to create a new desktop launcher/shortcut.

Currently your only have a script which you can run from the command line. Depending on what GUI desktop the process of creating a launcher may be different. For example this is how to create desktop shortcut launcher on Ubuntu with GNOME desktop.

I already have a desktop launcher. It runs the shell script above.

Insufficient information. Please read our guide on How to ask for help.