PC Review


Reply
Thread Tools Rate Thread

attach file as icon in a worksheet (hope it's not so tricky)

 
 
=?Utf-8?B?amFja28=?=
Guest
Posts: n/a
 
      2nd May 2005
i wish to create a button (from forms) and when click on it, it will pop up
the Insert Object dialog box, and automatically go to Create From File tab
with Display As Icon selected. Then it allows the user to select any file to
attach to the worksheet.

how do i do this with the button and macro? i hope it's not the tricky one
and appreciate experts out there can help.
 
Reply With Quote
 
 
 
 
Vasant Nanavati
Guest
Posts: n/a
 
      2nd May 2005
Not completely reliable, but:

SendKeys "{TAB}{TAB}{TAB}{TAB}{RIGHT}%a%n"
Application.Dialogs(xlDialogInsertObject).Show

--

Vasant



"jacko" <(E-Mail Removed)> wrote in message
news:579037D4-0BF6-41BD-BE65-(E-Mail Removed)...
> i wish to create a button (from forms) and when click on it, it will pop

up
> the Insert Object dialog box, and automatically go to Create From File tab
> with Display As Icon selected. Then it allows the user to select any file

to
> attach to the worksheet.
>
> how do i do this with the button and macro? i hope it's not the tricky one
> and appreciate experts out there can help.



 
Reply With Quote
 
Tom Ogilvy
Guest
Posts: n/a
 
      2nd May 2005
Sub showDialog()
'INSERT.OBJECT?(object_class, file_name, link_logical,
' display_icon_logical, icon_file, icon_number, icon_label)
ExecuteExcel4Macro "INSERT.OBJECT?(,""C:\"",False,True,)"
End Sub


--
Regards,
Tom Ogilvy


"jacko" <(E-Mail Removed)> wrote in message
news:579037D4-0BF6-41BD-BE65-(E-Mail Removed)...
> i wish to create a button (from forms) and when click on it, it will pop

up
> the Insert Object dialog box, and automatically go to Create From File tab
> with Display As Icon selected. Then it allows the user to select any file

to
> attach to the worksheet.
>
> how do i do this with the button and macro? i hope it's not the tricky one
> and appreciate experts out there can help.



 
Reply With Quote
 
Vasant Nanavati
Guest
Posts: n/a
 
      2nd May 2005
Nice one, Tom!

Regards,

Vasant

"Tom Ogilvy" <(E-Mail Removed)> wrote in message
news:%(E-Mail Removed)...
> Sub showDialog()
> 'INSERT.OBJECT?(object_class, file_name, link_logical,
> ' display_icon_logical, icon_file, icon_number, icon_label)
> ExecuteExcel4Macro "INSERT.OBJECT?(,""C:\"",False,True,)"
> End Sub
>
>
> --
> Regards,
> Tom Ogilvy
>
>
> "jacko" <(E-Mail Removed)> wrote in message
> news:579037D4-0BF6-41BD-BE65-(E-Mail Removed)...
> > i wish to create a button (from forms) and when click on it, it will pop

> up
> > the Insert Object dialog box, and automatically go to Create From File

tab
> > with Display As Icon selected. Then it allows the user to select any

file
> to
> > attach to the worksheet.
> >
> > how do i do this with the button and macro? i hope it's not the tricky

one
> > and appreciate experts out there can help.

>
>



 
Reply With Quote
 
=?Utf-8?B?amFja28=?=
Guest
Posts: n/a
 
      2nd May 2005
Excellent!!! Billions thanks to Tom!! and Vasant too!

"Tom Ogilvy" wrote:

> Sub showDialog()
> 'INSERT.OBJECT?(object_class, file_name, link_logical,
> ' display_icon_logical, icon_file, icon_number, icon_label)
> ExecuteExcel4Macro "INSERT.OBJECT?(,""C:\"",False,True,)"
> End Sub
>
>
> --
> Regards,
> Tom Ogilvy
>
>
> "jacko" <(E-Mail Removed)> wrote in message
> news:579037D4-0BF6-41BD-BE65-(E-Mail Removed)...
> > i wish to create a button (from forms) and when click on it, it will pop

> up
> > the Insert Object dialog box, and automatically go to Create From File tab
> > with Display As Icon selected. Then it allows the user to select any file

> to
> > attach to the worksheet.
> >
> > how do i do this with the button and macro? i hope it's not the tricky one
> > and appreciate experts out there can help.

>
>
>

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Outllook 2007 crashes when I click on Attach File Icon jweiss1113 Microsoft Outlook Discussion 4 17th Nov 2009 05:13 PM
attach icon on e-mail notification with no attach Barbara Microsoft Outlook Discussion 2 29th Jun 2009 07:27 PM
Mail worksheet in Body AND Attach File BenS Microsoft Excel Programming 3 21st Jan 2009 06:11 PM
How to attach Excel file (as an icon) to Microsoft document? =?Utf-8?B?cGF0aGFybA==?= Microsoft Word Document Management 1 24th Aug 2006 07:29 PM
Attach a file in a worksheet Vinay G Microsoft Excel Discussion 1 19th Jul 2005 01:07 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 04:47 PM.