Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
FCS FCS is offline
external usenet poster
 
Posts: 8
Default Restricting Paste in Excel

How can I restrict the "Paste" functionality in Excel to prevent the user
from pasting cell formats when copying and pasting? (i.e. only allowing
pasting values and/or formulas)

I am using Excel 2003
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 195
Default Restricting Paste in Excel

this might help you

http://p2p.wrox.com/topic.asp?TOPIC_ID=47526

FCS wrote:
How can I restrict the "Paste" functionality in Excel to prevent the user
from pasting cell formats when copying and pasting? (i.e. only allowing
pasting values and/or formulas)

I am using Excel 2003


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,391
Default Restricting Paste in Excel

This may give you a start. However, I can't seea way to differentiate a
..Paste from a .PasteSpecial, so you may have .Undo, then .PasteSpecial of
what you wish to allow.
Check the address of Target to see if you wish to control that range.

Dim Cutting As Boolean

Private Sub Worksheet_Change(ByVal Target As Range)
Dim Msg As String

With Application
Select Case .CutCopyMode
Case False
If Cutting Then
Msg = "Was Cut"
Else
Msg = "Normal Entry"
End If
Case xlCopy
Msg = "Pasted Copy"
'To disable .Paste
.EnableEvents = False
.Undo
.EnableEvents = True
End Select
End With
MsgBox Msg

End Sub

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Cutting = (Application.CutCopyMode = xlCut)
End Sub

NickHK

"FCS" wrote in message
...
How can I restrict the "Paste" functionality in Excel to prevent the user
from pasting cell formats when copying and pasting? (i.e. only allowing
pasting values and/or formulas)

I am using Excel 2003



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 113
Default Restricting Paste in Excel

Hi FSC,

I've tried this :
Sub diab()
Application.OnKey "^{v}", ""
Application.CommandBars.FindControl(ID:=22).Enable d = False
End Sub


Rgds,

Halim

FCS menuliskan:
How can I restrict the "Paste" functionality in Excel to prevent the user
from pasting cell formats when copying and pasting? (i.e. only allowing
pasting values and/or formulas)

I am using Excel 2003


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
Excel to Word : Paste specialPaste Link Excel Chart Obj doesn't Makedon Charts and Charting in Excel 0 January 12th 10 08:56 PM
row limits excel 2007 restricting pivot table calculations Jazz Excel Discussion (Misc queries) 0 August 8th 07 05:32 AM
Restricting Add-In functionality AMK4[_35_] Excel Programming 0 February 3rd 06 08:07 PM
Problem with Excel 2003 restricting functionality matthewDBS Excel Discussion (Misc queries) 1 August 12th 05 07:44 PM
Restricting save ability of an excel file YB Excel Programming 6 May 28th 04 01:57 PM


All times are GMT +1. The time now is 11:26 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"