Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 111
Default Excel Icon Programming

Trying to develop several worksheets, that will go out to several of our
facilities. When these facilities are loading these worksheets, all I want
them to do is install and icon on their deskup that will give them access to
these install sheets. I will have these sheets blocked so using this Icon is
their only way to gain access to the install sheets.

Can a desktop Icon be developed by using either Excel or VBA?

Steve
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default Excel Icon Programming

This will create a desktop shortcut if that is what you mean


'----------------------------------------------------------------
Sub CreateShortCut()
'----------------------------------------------------------------
Dim oWSH As Object
Dim oShortcut As Object
Dim sPathDeskTop As String

Set oWSH = CreateObject("WScript.Shell")
sPathDeskTop = oWSH.SpecialFolders("Desktop")

Set oShortcut = oWSH.CreateShortCut(sPathDeskTop & "\" & _
ActiveWorkbook.Name & ".lnk")
With oShortcut
.TargetPath = ActiveWorkbook.FullName
.Save
End With
Set oWSH = Nothing

End Sub



--
HTH

Bob Phillips

"caldog" wrote in message
...
Trying to develop several worksheets, that will go out to several of our
facilities. When these facilities are loading these worksheets, all I

want
them to do is install and icon on their deskup that will give them access

to
these install sheets. I will have these sheets blocked so using this Icon

is
their only way to gain access to the install sheets.

Can a desktop Icon be developed by using either Excel or VBA?

Steve



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 111
Default Excel Icon Programming

Thanks Bob

For everything to work correctly, and I am asking you this question becasue
I am fairly new at VBA code, where should this code be placed to work like I
want i to
?

Steve
"Bob Phillips" wrote:

This will create a desktop shortcut if that is what you mean


'----------------------------------------------------------------
Sub CreateShortCut()
'----------------------------------------------------------------
Dim oWSH As Object
Dim oShortcut As Object
Dim sPathDeskTop As String

Set oWSH = CreateObject("WScript.Shell")
sPathDeskTop = oWSH.SpecialFolders("Desktop")

Set oShortcut = oWSH.CreateShortCut(sPathDeskTop & "\" & _
ActiveWorkbook.Name & ".lnk")
With oShortcut
.TargetPath = ActiveWorkbook.FullName
.Save
End With
Set oWSH = Nothing

End Sub



--
HTH

Bob Phillips

"caldog" wrote in message
...
Trying to develop several worksheets, that will go out to several of our
facilities. When these facilities are loading these worksheets, all I

want
them to do is install and icon on their deskup that will give them access

to
these install sheets. I will have these sheets blocked so using this Icon

is
their only way to gain access to the install sheets.

Can a desktop Icon be developed by using either Excel or VBA?

Steve




  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 111
Default Excel Icon Programming

Still looking for help in how to use the code that Bob said to use, very new
at VBA.

Steve

"caldog" wrote:

Thanks Bob

For everything to work correctly, and I am asking you this question becasue
I am fairly new at VBA code, where should this code be placed to work like I
want i to
?

Steve
"Bob Phillips" wrote:

This will create a desktop shortcut if that is what you mean


'----------------------------------------------------------------
Sub CreateShortCut()
'----------------------------------------------------------------
Dim oWSH As Object
Dim oShortcut As Object
Dim sPathDeskTop As String

Set oWSH = CreateObject("WScript.Shell")
sPathDeskTop = oWSH.SpecialFolders("Desktop")

Set oShortcut = oWSH.CreateShortCut(sPathDeskTop & "\" & _
ActiveWorkbook.Name & ".lnk")
With oShortcut
.TargetPath = ActiveWorkbook.FullName
.Save
End With
Set oWSH = Nothing

End Sub



--
HTH

Bob Phillips

"caldog" wrote in message
...
Trying to develop several worksheets, that will go out to several of our
facilities. When these facilities are loading these worksheets, all I

want
them to do is install and icon on their deskup that will give them access

to
these install sheets. I will have these sheets blocked so using this Icon

is
their only way to gain access to the install sheets.

Can a desktop Icon be developed by using either Excel or VBA?

Steve




  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 162
Default Excel Icon Programming

You could put it in an Excel file with a single command button that
runs the macro, then email the Excel file to all your users.

Or you could put it in a VBS file (just a text file with a .vbs
extension) and mail that out. I don't know if it would make it through
the mail servers though - probably get tagged as a virus.



  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default Excel Icon Programming

Sorry to take so long to reply, different time zones meant I was fast asleep
when you posted :-).

The code should go into a standard code module (Alt-F11, InsertModule).

To know which workbook or whatever to add it to would require more detail on
how you will work with all of this, there are many options.

--
HTH

Bob Phillips

"caldog" wrote in message
...
Still looking for help in how to use the code that Bob said to use, very

new
at VBA.

Steve

"caldog" wrote:

Thanks Bob

For everything to work correctly, and I am asking you this question

becasue
I am fairly new at VBA code, where should this code be placed to work

like I
want i to
?

Steve
"Bob Phillips" wrote:

This will create a desktop shortcut if that is what you mean


'----------------------------------------------------------------
Sub CreateShortCut()
'----------------------------------------------------------------
Dim oWSH As Object
Dim oShortcut As Object
Dim sPathDeskTop As String

Set oWSH = CreateObject("WScript.Shell")
sPathDeskTop = oWSH.SpecialFolders("Desktop")

Set oShortcut = oWSH.CreateShortCut(sPathDeskTop & "\" & _
ActiveWorkbook.Name & ".lnk")
With oShortcut
.TargetPath = ActiveWorkbook.FullName
.Save
End With
Set oWSH = Nothing

End Sub



--
HTH

Bob Phillips

"caldog" wrote in message
...
Trying to develop several worksheets, that will go out to several of

our
facilities. When these facilities are loading these worksheets, all

I
want
them to do is install and icon on their deskup that will give them

access
to
these install sheets. I will have these sheets blocked so using

this Icon
is
their only way to gain access to the install sheets.

Can a desktop Icon be developed by using either Excel or VBA?

Steve





Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Icon Sets - Display icon in one cell depending upon value in anoth Nolene Excel Worksheet Functions 2 February 26th 10 05:43 AM
Excel Icon Kathy Excel Discussion (Misc queries) 0 January 10th 10 03:04 AM
Icon Programming caldog Excel Programming 0 September 14th 05 02:09 AM
Excel Icon MD Excel Programming 1 March 14th 05 04:48 PM
Excel Icon nathan Excel Programming 0 August 9th 04 03:34 PM


All times are GMT +1. The time now is 05:45 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"