Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
Creating A spreadsheet with an Update Function
I am trying to create a spreadsheet with 2 active sheets. I would like an
Update Button on Sheet 1. Based on certain information that is entered on Sheet 1, when the Update Button is pressed, the information would then be automatically copied into Sheet 2. Can someone tell me how to accomplish this? It would be greatly appreciated! -- TJ |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
Creating A spreadsheet with an Update Function
On sheet1, create a shape ( your button )
you can add the text "update on it if you wish then either edit the code below to suit your needs, or better create a quick macro for yourself: TOOLS MACRORECORD NEW MACRO ( you can name it) then do exactly what you want the macro to do, ie: copy cells, select another sheet, paste or paste special where you want the data, return to sheet1 now STOP RECORDING ( there will be an icon, or go to TOOLS MACRO STOP RECORDING Now right click on your autoshape ( button) assign macro, select the macro you wrote.... Sub Update() Range("A1:F21").Select Selection.Copy Sheets("Sheet2").Select Range("A1").Select Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _ :=False, Transpose:=False Range("A1").Select Sheets("Sheet1").Select Application.CutCopyMode = False Range("A1").Select End Sub "TJ" wrote: I am trying to create a spreadsheet with 2 active sheets. I would like an Update Button on Sheet 1. Based on certain information that is entered on Sheet 1, when the Update Button is pressed, the information would then be automatically copied into Sheet 2. Can someone tell me how to accomplish this? It would be greatly appreciated! -- TJ |
#3
Posted to microsoft.public.excel.misc
|
|||
|
|||
Creating A spreadsheet with an Update Function
Thank you for your assistance.
-- TJ "ufo_pilot" wrote: On sheet1, create a shape ( your button ) you can add the text "update on it if you wish then either edit the code below to suit your needs, or better create a quick macro for yourself: TOOLS MACRORECORD NEW MACRO ( you can name it) then do exactly what you want the macro to do, ie: copy cells, select another sheet, paste or paste special where you want the data, return to sheet1 now STOP RECORDING ( there will be an icon, or go to TOOLS MACRO STOP RECORDING Now right click on your autoshape ( button) assign macro, select the macro you wrote.... Sub Update() Range("A1:F21").Select Selection.Copy Sheets("Sheet2").Select Range("A1").Select Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _ :=False, Transpose:=False Range("A1").Select Sheets("Sheet1").Select Application.CutCopyMode = False Range("A1").Select End Sub "TJ" wrote: I am trying to create a spreadsheet with 2 active sheets. I would like an Update Button on Sheet 1. Based on certain information that is entered on Sheet 1, when the Update Button is pressed, the information would then be automatically copied into Sheet 2. Can someone tell me how to accomplish this? It would be greatly appreciated! -- TJ |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Function Update | Excel Worksheet Functions | |||
How to make a function in a cell update | Excel Discussion (Misc queries) | |||
Creating a function | Excel Worksheet Functions | |||
Creating a Custom Excel Function to Calculate Gini Coefficients | Excel Worksheet Functions | |||
creating function (vba) with range arguments | Excel Worksheet Functions |