1.select

  1. Belair58

    Loop through all WorkSheets is not working, code review please.

    Hello, I have a workbook with multiple sheets and I'd like to run this macro on all sheets. The code below will run on the first worksheet, but not on all. If anyone can see why it's not looping through all the sheets I'd appreciate it. <Code> Sub Add_On_Time_Or_Not_To_Each_Sheet() Dim ws As...
  2. S

    Referencing another Worksheet in VBA

    I was given this project to develop a form that by a click a button will send the answers to a separate table. It currently works. The user fills out the form in "Change Order Form (sheet1)" , when finished the submit button is clicked which then sends the responses a table in "Change Order Log...
  3. P

    Personal Macro to replace selection value

    Hello everyone, I am trying to do a very simple macro to replace date formats from MM/DD/YYYY to DD/MM/YYYY using a macro that I could use with some shortcut on my current selection on Excel : Sub dateus_fr() Dim date_us As String Dim date_fr As String Dim replace1 As String date_us =...
  4. R

    Populate Table from list box

    Hello, First off this is my first post, normally i can find my solutions but i can't quite figure it out this time, so sorry if this has already been asked. I'm designing a workbook where users can update the data through a userform. Currently the userform has a listbox that pulls from a...
  5. D

    macro messing up table

    i have a table with three columns...whenever i use the macro to enter new data in the table, it messes it up and it's no longer dynamic. after the macro, if i manually enter data again, the table does not expand. 'put time stamp Sheets("Time Stamp").Select finalrow = Cells(Rows.Count...
  6. D

    Moving Data and delete transferred data.

    Hi, I have a worksheet (Sheet1) with data in each row. I want the data in Sheet1 to be transferred to sheet2 if column 10 (J) equals "Yes", and once transferred/copied to sheet2, the data is deleted from sheet1 and the all the blank rows are deleted. Column 10 value will be either Yes or No. Any...
  7. J

    VBA to upload Data from Excel to Access

    Hi, Not sure if I should post this on the excel or access forum butthought I would try here first. I have used the below code in the past to upload data to MSaccess 2010 from Excel 2010 , but I am now using MS 2013 and the code is nolonger working. I am receiving the error unrecognised...
  8. M

    Create a table after performing a action, VBA

    Hello, I have a VBA code that I had made, but having a difficult time making a table from it. It has to be from a current selection, instead of A5 as it is never in the same cell in each workbook. Can someone help me? Sub template() ' ' template Macro ' ' ActiveCell.Select...
  9. P

    VBA Help required

    Hi Guys, I have written the below code.... I am trying to delete all column between B1 and M1 where the value is not equal to that in R1. (to get the column headings/cell references i need to delete first 13 rows) With ActiveSheet ActiveSheet.Rows("1:13").Delete End With With ActiveSheet...
  10. T

    VBA Create a table

    Hi Guys, I have recorded a macro to create a table which works fine but i'm wondering if there is a way to change the range so it looks to the last row in column P rather than the selected range. Hope this makes sense. Thanks Sub CREATE() Sheets("Bethan").Select Range(Selection...
  11. D

    Issue passing values between userforms

    Ok, soo... i am having trouble passing the values from combobox and textbox from userform1 to userform3 i have made Cust, PrtNmb and WrkNmb private objects Sub CommandButton1_Click() Range("a1").Select With ActiveSheet .Range("A1").End(xlDown).Activate 'moves to end of data...
  12. D

    Help - script loops through a range of cells, compares, and makes a change when match is found

    I tested this script and it walks through all 27000 cells (D3 - AZ500), changing each that is not blank to a red background: Dim MyVar As String Dim i As Integer Range("D3").Select For i = 1 To 27000 If ActiveCell.Value = "" Then ActiveCell.Offset(1, 0).Select Range("D" &...
  13. W

    How to add a else statement to code

    Hello all, I am using the below code to copy specific cell values and paste the entire row into a new worksheet. I am having trouble finishing the code. After the last ElseIf statement i want to add another ElseIf or Else (not sure which one i would use) that will move the rest of the data...
  14. J

    Very slow VBA

    Hello, I'm quite new to VBA and I just recently wrote this code to extract data from one main worksheet to copy/paste into each respective client worksheet. Contained in the workbook is a main worksheet with currently over 5000 entries and then the 14 separate client worksheets. Two...
  15. N

    rows instea cell

    In this macro count blank active cell in active worksheet but i like count blank row instead active cell in workssheet "DATA" Sub FillDateSenderFrom() For i = 1 To 3 If Controls("TextBox" & i) <> "" Then If i = 1 Then Cells(Rows.Count...
  16. M

    Referencing to a sheet a newly created sheet in excel vba formula

    Hello excel experts, New vba rookie here. I'm doing a project for my company and I'm creating a VBA macro for it. This is the code Sub CreateNewSheet() Dim i As Byte - Here the user creates a Name for the new sheet in which he needs to input some data. sheet_name_to_create = InputBox("Vul...
  17. rjplante

    Run-time error '13': Type mismatch ??

    I am getting a Run-time error '13': Type mismatch flag on the code line listed below. I do not know why it is failing at this point. The data is all formatted as Number so the data format is the same. I am at a loss as to why this is failing. Any support or direction is appreciated. '...
  18. B

    Creating customer statement and email with xls attachment

    Hi all I am new to this forum. I have seen some pretty amazing VBA codes/help here. I would like to get involved. I am a management accountant and I often create workbooks for myself and colleagues to save time and improve efficiency. To start off, I am sharing the following code which I...
  19. S

    Application Defined or Object Defined Error

    I am receiving the "Application Defined or Object Defined Error" on line Selection.End(xlToRight).Offset(0, 1).Select The entire chunk is this: COM.Worksheets(AC).Activate Cells(j, 1).Offset(-1, 0).Select Selection.End(xlToRight).Offset(0, 1).Select b =...
  20. S

    Error:

    Greetings again, I am receiving an error "wrong number of arguments or invalid property assignment" on the line below: Set Fnd = MAIN.Worksheets("M_" & AC).Range.Find(What:=COM.Worksheets(AC).Cells(j, 1).Value, After:=MAIN.Worksheets("M_" & AC).Cells(1, 1), LookIn:=xlValues, LookAt:=xlWhole...

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top