Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 5
Default Pictures in Forms

Hi

I'm setting up a form and have unlocked the cells that need input and the
form is running okay including all the picklists etc. But in some of the
cells I require photographs inserting by the users and can't work out how to
format the cell or protection to allow this. Please could someone help?
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 172
Default Pictures in Forms

Sub Insert_Pict()
Dim Pict
Dim ImgFileFormat As String
Dim PictCell As Range
Dim Ans As Integer

ActiveSheet.Protect True, True, True, True, True
ImgFileFormat = "Image Files (*.bmp),others, tif (*.tif),*.tif, jpg
(*.jpg),*.jpg"

GetPict:
Pict = Application.GetOpenFilename(ImgFileFormat)
'Note you can load in any nearly file format
If Pict = False Then End

Ans = MsgBox("Open : " & Pict, vbYesNo, "Insert Picture")
If Ans = vbNo Then GoTo GetPict

'Now paste to userselected cell
GetCell:
Set PictCell = Application.InputBox("Select the cell to insert into",
Type:=8)
If PictCell.Count 1 Then MsgBox "Select ONE cell only": GoTo GetCell
PictCell.Select
ActiveSheet.Pictures.Insert(Pict).Select


End Sub



"SusieQ" wrote in message
...
Hi

I'm setting up a form and have unlocked the cells that need input and the
form is running okay including all the picklists etc. But in some of the
cells I require photographs inserting by the users and can't work out how
to
format the cell or protection to allow this. Please could someone help?



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
Deleting Pictures to reduce workbook size Stephen POWELL Excel Discussion (Misc queries) 4 November 13th 06 11:38 PM
Interaction of form controls and pictures in Excel 2007 keithrmanning Excel Worksheet Functions 7 November 9th 06 03:39 PM
Component not correctly registered Error opening Forms in Excel melliott1963 Excel Discussion (Misc queries) 0 May 26th 06 12:40 PM
Excel and pictures....a few questions... marko Excel Discussion (Misc queries) 3 February 15th 06 06:45 AM
Custom Button Pictures Sloth Excel Discussion (Misc queries) 1 January 13th 06 01:08 AM


All times are GMT +1. The time now is 04:34 AM.

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

About Us

"It's about Microsoft Excel"