Excel 2013 :: How To Record Printer Info With Macro Recorder

Dec 6, 2013

Had 2003 now 2013. Trying to get the macro to select different printers for different doccuments. 2013 macro recorder does not record any printer info or path, all printers show the same wording just application print...

How can I get the recorder to acurrately record and diferentiate printers?

View 2 Replies


ADVERTISEMENT

Excel 2011 :: Macro Recorder Doesn't Record Fill Color

Oct 11, 2011

I am using office 2011 for MAC, and am trying to create a macro that changes the color of the selected cell(s).

if I start recording the macro
click the fill color button pull down and change the color on the edit section of the ribbon
Stop the macro

No code is recorded as below but the cell did change color to whatever I selected.

Sub Macro13()
'
' Macro13 Macro
'

'
End Sub

[code].....

The colorIndex is automatic no matter what color I choose.

When I run the macro there is no change to the selected cell, but the border is destroyed.

View 2 Replies View Related

Record Data From A Cell Which Contains Info

Nov 7, 2008

What I'm trying to put together is a sheet where i work out how much margin i will be making on a sale (which i done). The bit I'm stuck with is the recording the data on a separate sheet.

What i have done so far.
I created a Macro button to insert and copy cells C6, C7 & C8 (the bits i need). Which works but it takes the formular with it so everytime i chage the figure on sheet 1 it changes in sheet 2.

So what i'm asking is there a way to mirror what is display rather that copy?

View 14 Replies View Related

Launching Macro Recorder Using VBA

Jun 9, 2009

I hide all Excel standard tabs and thus need a button on custom tab to record a macro. (I did this successfully with custom menu in Excel 2003.) In 2007 ribbon, I've reused the code for a button's OnAction, now going to callback that runs:

Application.CommandBars.ExecuteMso ("MacroRecord")

In Excel 2003, the stop button appeared automatically for me. But in Excel 2007, with hiding standard tabs, etc., I see no way to stop recording, other than running my button to return the Developer's tab, where the Record Macro button has changed to Stop Macro.

I'd like to either add a second button to my ribbon to stop recording the macro (but I can't find an idMso to use in a callback) or have my Record button change to Stop button, like Excel does. But I can't come up with correct code.

View 4 Replies View Related

Macro Recorder Appears

Jun 10, 2009

I used macro recorder, and this code was the result. Is there a way to shorten this code up? The more I use macro recorder, the more I'm beginning to realize that the code generated from macro recorder can be very sloppy.

View 8 Replies View Related

Macro Recorder Not Working On Other PC

Jul 7, 2009

Have recorded a Macro which is doing a great job, but when i try to run the same macro from other pc its not running,pops an search error.

View 9 Replies View Related

Using MAcro Recorder To Store Variables?

Jun 22, 2006

Is it possible to use the Macro recorder in Excel to store user variables that they put in through a UserForm? So say when a textbox on a userform is changed, it records a macro of what is put into the textbox, which it can then call to retrieve the value.

View 4 Replies View Related

Edit Code From The Macro Recorder

Jul 25, 2006

The way i have been creating macros is by going to the tools menu.....macro....then..... record new macro.

I have a file which I have re-formatted using a macro as described above however because i receives files every month to do updates every time i open a new file and try to perform that same macro it either wont work or it wont format the correct rows.......is VBA the solution to this????

View 9 Replies View Related

Excel 2013 :: Macro To Update New Sheet?

Jun 23, 2014

I've got a spreadsheet that pulls data from a SQL server.

I'm looking to have a button on the first sheet that extracts the data from SQL and inserts it into sheet 2 of spreadsheet. The data connection from SqL is working fine but when I click on the button sheet 2 is blank.

View 1 Replies View Related

Excel 2013 :: Using Macro To Format Table?

May 14, 2014

I am using excel 2013. I have the table look like the above, in the diagram 1, i want to have the macro such that it can be formatted to the 2nd diagram. Can this be done using macro ? [URL]

View 2 Replies View Related

Excel 2013 :: Extract Date And Time Info From A Text Cell That Contains Text And Date And Time

Jul 19, 2014

I am using Excel 2013. Anyway, the first issue is that I need to pull a date and a time period from text. So, for example, if I see something like Sunday Prime Time 7/6/14 8:37PM, I would want to pull ONLY the "7/6/14 8:37PM" out of it. Each text box could potentially be different, so it might not always be in the same format as "Sunday Prime Time 7/6/14 8:37PM" it might only show just the date and/or the time without all the extra text i.e. 7/6/14 8:37PM. Some of the cells will have text, others might only have just the time or even just the date and the time. The only thing that I am worrying about in each cell is extracting just the date and time. If this is too much to ask of excel, I would be ok with extracting ONLY the time - 8:37PM and not the date, but I would much rather be able to get both the time and date.

THEN, onto part two of my question. After I would pull the dates and times, I need to compare them with each other. So, when I have the same date with two separate times on that date, I need to write a formula to show if those times on that date are less than 30 minutes apart. So, if I have 6 times on 7/6/14, I need to know if any of them are less than 30 minutes apart.

I would need to have the formula say something like "Problem" if the times on 7/6/14 would be 5:30PM, 5:48PM, 7:00PM, 8:00PM, 8:15PM, and 9:00Pm for example. I would like to see the word "Problem" since 5:30PM and 5:48Pm is only 18 minutes apart, and "Problem" after 8:15PM since that is only 15 minutes past the 8:00PM which is obviously under 30 minutes. The times that are more than 30 minutes apart such as 7:00PM and 9:00PM for example are more than 30 minutes apart from any of the other times that were extracted.

View 7 Replies View Related

Macro Recorder To Create A Pivot Table

Sep 30, 2008

I used the macro recorder to create a pivot table, but to verfity that it works.

I get a "Add fields method of Pivot Table class failed"..

and this was highlighted:

ActiveSheet.PivotTables("PivotTable2").AddFields RowFields:=Array("Warehouse" _
, "Product", "Description", "Data")

View 9 Replies View Related

Excel 2013 :: Macro That Can Reference Worksheet It Has Created

Jul 4, 2014

I am completely new to Macro's and VB and the macro below has been generated using the "Record Macro" function in Excel 2013 with a couple of very minor modifications based on some research I have done (hyperlink & input box). My ultimate goal is to make a copy of my "TEMPLATE", which is hidden and the copy could have a variety of names, then create an entry in my "SUMMARY" table that references cells on the newly created sheet. The new entry on the SUMMARY page should be entered in the next available row ... at the moment I need to make sure I have my cursor in the right place before I run the macro. I also want the first cell in the new "SUMMARY" row to create a hyperlink to the newly created worksheet.

The macro does what I need it to do, as long as I name the new sheet "Test", what I would like is for the Macro to recognise the name of the new worksheet and create links to that name. The rows and columns in each new sheet will remain the same, hence the R##C## part will always work.

The "SUMMARY" and "TEMPLATE" worksheet names will not (ever) change.

View 4 Replies View Related

Excel 2013 :: Enabling Undo After Running A Macro?

Mar 18, 2014

A coworker just ran something by me that i'm quite frankly baffled by. After running a macro, the undo function becomes disabled up to the point of when the macro was ran. I've done a quick search through the forums and can't seem to find this question so i thought i'd ask.

Is there an option to toggle somewhere or 3rd party addon that keeps Undo enabled after running a macro? On a similar topic for my own curiosity, what's the reason that it disables?

View 3 Replies View Related

Excel 2013 :: Define Font Colour Within Macro

Apr 3, 2014

Excel 2013

I am trying to define a font colour within a macro When I record the macro, I choose a colour from the font colour-picker in the Home section of the ribbon. The colour I choose is one of the grey shades Everything seems to work ok, and the macro saves with the colour defined as a long number, e.g.

.Bold = False
.Italic = False
.ThemeColor = xlThemeColordark2
TintAndShade = -0.499984740745262

(Note this is the colour number returned by Excel when I chose a grey font) But when I run the macro, instead of a grey font I get a sort of pale apricot

Do I need to re-index something?

Is there a list anywhere of these long numbers and the colours that they represent?

View 2 Replies View Related

Excel 2007 :: Macros Enabled But Record Macro Grayed Out

Apr 14, 2008

I have excel 2007 and I want to record a macro. I have enabled all macros via the Trust Center settings and have even saved the current workbook (created from scratch in 2007) to a macro-enabled version.

But when I click on the 'developer' toolbar, 'record macro' is grayed out.

View 9 Replies View Related

Macro Recorder :: Compile Error: Argument Not Optional

Aug 24, 2007

I have recorded a simple macro ( copying a cell, and then pasting the formula into various others), and I get the following error

Compile Error: Argument Not Optional

I have highlighted where the error first happens

Sub Macro3()
'
' Macro3 Macro
' Macro recorded 24/08/2007 by Michael Traynor
'

'
Range("K7:K8").Select
Selection.Copy
Range("K167:AJ168").Select
Range("AJ167").Activate
Range("K167:AJ168,K175:AJ176").Select
Range("AJ175").Activate
Range("K167:AJ168,K175:AJ176,K183:AJ184").Select
Range("AJ183").Activate
Range("K167:AJ168,K175:AJ176,K183:AJ184,K191:AJ192").Select

As I've said I didn't write this, it was recorded from Excel.

View 7 Replies View Related

2007 Macro Recorder Not Recording Chart Property Changes

Sep 4, 2007

I've created VBA code in Access 2007 to create a column chart in Excel, and it is working. I need to change the rotation on my category labels to 270 degrees vertical. When I record a macro on the chart in Excel 2007. I only receive the following

Sub chartingRotation()
'
' chartingRotation Macro
'

'
ActiveSheet.ChartObjects("Chart 1").Activate
ActiveChart.Axes(xlCategory).Select
ActiveSheet.ChartObjects("Chart 1").Activate
End Sub

How can I get the macro recorder to record changes to chart properties?

View 4 Replies View Related

Excel 2013 :: VBA Macro For Selecting Current Week Range

May 30, 2013

I currently have this beast of a code running in Excel 2013:

HTML Code:
Sub OBTAIN_RAW_DATA_MACRO()
Dim NextCol As Long

'Copy data
Workbooks.Open Filename:= _

[Code] ........

However the issue lies in that once the data is refreshed, the slicers reading off the above raw data/pivots, automatically select all weeks, however this is not beneficial for the data being presented.

Is there anyway to have, once the Pivots have been updated, for the macro to then check and select current week range (beginning Monday) only?

View 4 Replies View Related

Excel 2013 :: Customize Macro Button Added To Toolbar

Dec 3, 2013

Upgraded to Excel 2013. Do i no longer have the ability to customize the look of my macro buttons i add to the toolbar?

View 2 Replies View Related

Excel 2013 :: Can't Find Macro In Inherited File - How To Search In VBA

Apr 8, 2014

So there's a macro "RoundedRectangle4_click" that's assigned to a box on a worksheet. It's a simple macro, I assume. it just takes the user to the 'Main Sheet' tab. I know the name b/c I rightclicked on the box to get the Macro Assigned.

I click on Macros (F8), it's not listed there, but"RoundedRectangle5_click" is, so I click on it, edit it to match the one I'm searching. Nope, nothing. CREATE button is highlighted.

I've gone to VBA (AltF11) to try to find it among the 25+ worksheets, forms & modules - haven't found it yet.

View 4 Replies View Related

Macro Recorder - Select Method Of Range Class Failed?

Oct 11, 2012

I have used the macro recorder to generate the select range and clear part of the following macro.

Private Sub CommandButton2_Click()
Dim test As Worksheet
Sheets("Industry").Copy After:=Sheets(Sheets.Count)

[Code]....

I get the runtime error 1004 - Select method of range class failed.

I have used similar script in other macros without error.

View 2 Replies View Related

Excel 2013 :: Format Date / Time And Macro To Run On Opening Orkbook

Feb 2, 2013

I need to place a date and time in a cell 14/9/2013 6:00 PM

Tried several formats under custom format without success.

Also need addition to following macro to enable it to start on opening of workbook

Code:

Sub Macro1()
Do
PauseTime = 1 ' Set duration.
Start = Timer ' Set start time.
Do While Timer < Start + PauseTime
DoEvents ' Yield to other processes.

[Code]...

View 8 Replies View Related

Excel 2011 :: Write And Record A Macro To Link To A Button To (go To Layout And Cell)

Feb 22, 2014

Using excel 2011 for mac and would like to learn how to write and record a macro to link to a button to "go to a layout and cell"

View 4 Replies View Related

Excel 2013 :: File Size Grows When Using Macro To Copy / Paste To New Workbook

May 9, 2014

I'm using Excel 2013 on Windows 7.

I have an Excel file which has a macro that sucks in data from a number of separate files (two Excel, a varying number of csv). The macro grabs all the individual files and loads them into one of three worksheets with some formatting, sorting, and structuring on the way. All good so far.

I then need to take two of the worksheets and copy them to a new Workbook which I can send out to some users. So I use the Workbooks.Add method, and use the Selection.Copy on just the data (UsedRange.Rows/Columns.Count to ensure it is only the data) and Selection.PasteSpecial with the xlPasteColumnWidths, xlPasteValues, and xlPasteFormats options to copy the data over. None of the data is filtered. Just straight data.

I would expect the newly added workbook to be smaller than the one with the macros because the one with the macros has two extra sheets that I don't transfer, and the sheets I do transfer are identical.

And that's where it gets weird. The file with the macros and more data is 18.7Mb, but the new one with only two sheets is 24.8Mb. One is .xlsm and the other is .xlsx (because it has no macros).

I've tried opening the new workbook and saving as .xlsm (no material difference to the size) and as .xls (it got even bigger). I've opened the new workbook, gone to the end of the data and deleted all the blank rows and columns, but no effect (because the rows are already empty).

Why would the file with less in it be so much bigger (or bigger at all)?

View 2 Replies View Related

Excel 2013 :: Macro - Paste To Column Cell Location Based On Variable?

Jun 16, 2014

I have data in E6-E67 on Sheet 1. Based on the date in A2 on that sheet, I need to paste to a column in Sheet 2. In excel, I am able to get the cell location through vlookup and get the correct column number/cell reference. When it gets to the paste location, I am stumped on how to format that line of code? Do I need sometime of variable? I tried to use the address/lookup code but it does not work.

I have excel 2013.

View 4 Replies View Related

Macro To Print Record # To Record#

Mar 20, 2009

I'm trying to find a macro that will run allowing the user to select a 'starting record number' and a 'finishing record number' when printing.

I have a spreadsheet that feeds from a master list in excel, from over 5000 records.

I need to print the s'sheet with any given indivdual record's information at any given time.

Individual prints are fine. However if I wanted to print from record number 1500 to record number 3000 it would take me all day.

Is there a way I can set up a macro so an option form pops up? allowing selection of "From record" and "to Record" ?

View 13 Replies View Related

Printer Detection Macro In VBA

Jun 13, 2009

i have a workbook system that is used on 25 standalone machines that all have different printers everytime i install on a new system i have to reconfigure all of the printers that i have set up in VBA i am curious to find out as to whether or not there is a macro i can use that will generate a list of all printers on a machine that i can then use to refrence a printer name in my VBA

View 3 Replies View Related

Macro Print To Default Printer

Mar 16, 2009

i have a macro that loads a userform for previewing and printing selected sheets. The macro works fine for previewing sheets but when i choose the print button the marco trys to save the file as a .mdi, i want this to select the default printer on the pc instead, the excel file will be onpened on many different pcs so the printers will be different on each machine, hence why i want a default printer selected. This is the section of code from the form

View 2 Replies View Related

Macro To Print To Specific Printer

Jun 15, 2009

I am trying to swith between different printers to print out sheets within a single workbook. Recording the macro doesn't work very well and the code I found online doesn't work either (error: object doesn't support property).

How can I set this up to be a dynamic printer setting?
Code I tried:

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved