The forum

New script for PowerPointViewer2003

Author Replies
vampyre2000 Wednesday 24 June 2009 at 6:53
vampyre2000Anonymous

Hi,
This is my first scripts for Play on Linux.
I recently had to install Powerpoint viewer so I though this would be a good way to get my hands dirty.
All seems to work fine so far.
Any testers can give me any feedback?

Wine version: 1.1.24
Distribution: Ubuntu 9.04
Distribution Jaunty 32 bits
Comments: This script will download and install Microsoft Powerpoint viewer 2003.

Thanks

#!/bin/bash
if [ "$PLAYONLINUX" = "" ]then
exit 0
fi
source "$PLAYONLINUX/lib/sources"
 
cfg_check
 
POL_SetupWindow_Init
POL_SetupWindow_presentation "PowerPointViewer" "Microsoft" "http://www.microsoft.com/" "vampyre2000" "PowerPointViewer"
 
select_prefixe "$REPERTOIRE/wineprefix/PowerPointViewer"
POL_SetupWindow_prefixcreate 
 
cd "$REPERTOIRE/wineprefix/PowerPointViewer/drive_c/"
POL_SetupWindow_download "Downloading PowerPointViewer2003..." "Downloading PowerPointViewer2003..." "http://download.microsoft.com/download/a/1/a/a1adc39b-9827-4c7a-890b-91396aed2b86/ppviewer.exe"
POL_SetupWindow_wait_next_signal "Installation in progress..." "PowerPointViewer"
wine "$REPERTOIRE/wineprefix/PowerPointViewer/drive_c/ppviewer.exe"
POL_SetupWindow_detect_exit
 
POL_SetupWindow_make_shortcut "PowerPointViewer" "Program Files/Microsoft Office/PowerPoint Viewer/" "PPTVIEW.EXE" "" "PowerPointViewer2003"
 
POL_SetupWindow_reboot
POL_SetupWindow_Close
exit

Edited by vampyre2000

NSLW Wednesday 24 June 2009 at 9:19
NSLW

Hi,

your script needs some improvements. You may wish to check this script and treat it as a guide
vampyre2000 Thursday 25 June 2009 at 8:02
vampyre2000Anonymous

Many thanks for your feedback.
I am still new to this, so please forgive any bad coding.

I have tested my new script with the ideas that you have send it and it works fine.
Please any testers look over this.

#!/bin/bash
# Date: (2009-06-24)
# Last revision: (2009-06-25 16-00)
# Distribution used to test: Ubuntu 9.04
# Wine version used: 1.1.24 
# Author: vampyre2000
 
[ "$PLAYONLINUX" = "" ] && exit 0
source "$PLAYONLINUX/lib/sources"

#PREFIX, TITLE AND MESSAGES
PREFIX="PowerPointViewer"
TITLE="PowerPointViewer 2003"
PUBLISHER="Microsoft"
AUTHOR="vampyre2000"
DOWNLOADNAME="http://download.microsoft.com/download/a/1/a/a1adc39b-9827-4c7a-890b-91396aed2b86/ppviewer.exe"
LNG_SSF="has been installed successfully"
cfg_check

#DOWNLOADING AND SELECTING INSTALLER IMAGE
POL_SetupWindow_Init
POL_SetupWindow_presentation "$TITLE" "$PUBLISHER" "http://www.microsoft.com/" "$AUTHOR" "$PREFIX"
cd "$REPERTOIRE/tmp"
POL_SetupWindow_download "Downloading PowerPointViewer2003..." "Downloading PowerPointViewer2003..." "$DOWNLOADNAME"

#SELECTING PREFIX 
select_prefixe "$REPERTOIRE/wineprefix/$PREFIX"
POL_SetupWindow_prefixcreate 

#INSTALLING IMAGE
POL_SetupWindow_wait_next_signal "Installation in progress..." "$TITLE"
wine "$REPERTOIRE/tmp/ppviewer.exe"
POL_SetupWindow_detect_exit

#MAKING SHORTCUT 
POL_SetupWindow_make_shortcut "$PREFIX" "Program Files/Microsoft Office/PowerPoint Viewer/" "PPTVIEW.EXE" "" "$TITLE"

#CLEANING TEMP
clean_tmp

#FINISHING
POL_SetupWindow_message "$TITLE $LNG_SSF" "$TITLE" 
POL_SetupWindow_reboot
POL_SetupWindow_Close
exit
NSLW Thursday 25 June 2009 at 20:42
NSLW

You also should make something with "Program Files" directory. What to do is also mentioned in link i gave earlier.

This site allows content generated by members, and we promptly remove any content that infringes copyright according to our Terms of Service. To report copyright infringement, please send a notice to dmca-notice@playonlinux.com