c.value

  1. G

    Error with the below code "Can't find project or library"

    Hi Everyone, I am working in a project and below is my complete code. Option Explicit Sub Try() Dim TOrig As String, STMonth As Long, SCMonth As Long, ECMonth As Long Dim I As Long, J As Long, CMon, cCol As Long Dim lrow As Long Dim add_month As String add_month = InputBox("Insert the...
  2. detweiler

    Updating macro functionality

    Okay, so really weird, because I thought I had received help with this macro here, but found that there weren't any replies to my initial request ( ? ). So, I have this macro - Dim c As Range, d As String For Each c In Range("J2", Range("J" & Rows.Count).End(xlUp)) If c.Value Like...
  3. F

    VBA: Move thru columns with an array

    I'm trying to cycle thru some columns, but can't get this array correctly implemented. It would be easy to use a For loop with a step of say 4, but unfortunately the last column is 5 columns to the right. Ultimately this is column BL, BP, and BU. Sub AverageCells() Dim x As Long Dim c...
  4. Z

    Update Cross Reference in Word from Excel

    Hello all, I have an excel spreadsheet that i have added coding to fill out a word document. The current coding fills in a few text fields throughout the document. My issues is that there are a few points in the document i have filled with Cross Reference fields. The problem is when i run my...
  5. T

    Set cell not showing value

    I want to show c.Value in the set Range elrepcol. elrepcol remains blank. How to show c.Value in the cell? For Each c In ActiveSheet.Range(("D131"), _ Range("D131").Offset(, 40).End(xlToLeft)) _ .Cells Set elrepcol = Range("AK1").End(xlToLeft).Offset(, 1) elrepcol = c.Value
  6. F

    VBA to create Tab-delimited text file with Number Formats

    Hi, I'm new to this Forum as to VBA and Macro's. I'mm hoping you can help me with the following since I'm not finding any copy/paste solution:(. Currently I'm working on an excel file that serves as input for InDesign. My challenge is to automate the following: Excel formulas help me to fill a...
  7. B

    VBA Case Else working / Case not working

    Dim c As Range Dim i As Long For Each c In Range("C1:Z1") For i = 2 to 26 Select case i Case 7, 12, 17, 22 c.Value = "=" & c.Offset(0, -1).Address & "+3" Case Else c.Value = "=" & c.Offset(0, -1).Address & "+1" End Select Next Next The above just...
  8. A

    Using Goal Seek on multiple columns and rows in VBA

    Hello, I have been using a macro for a while now to perform a Goal Seek on several cells in a row one after the other: Sub PTUSeek() Dim Cell, OS, Target, Adj Set Target = [I4:FW4] Set Adj = [I3] OS = Adj.Row - Target.Cells(1).Row For Each Cell In Target.Cells...
  9. B

    .value = .value

    I am guessing there isn't a possibility of this based on the purpose of .value; But I am looking if there is a possibility of also taking the format on a .value = .value I am trying to avoid a copy and paste I have an example below Dim c As Range For Each c In Range("A2:B" &...
  10. H

    Speed up camparing two workbooks VBA

    Help Please, this code is taking to long to complete. I believe because of the two Loops, each loop contains 100 cells so it is looping through 10000 cells and taking about 6 mins to complete. My guess is there is another way to do this and not take so long. Any help would be appreciated...
  11. B

    Consolidate If

    Evening Is there a simpler way to perform this action. and possibly center align the offset value without a new loop. Thanks guys :) Dim r As RangeSet r = Range("Z3", Range("Z" & Rows.Count).End(xlUp)) For Each c In r If c.Value = "AmountPaid" Then c.Offset(, 8) = "Close" If c.Value = "Amount...
  12. M

    VBA to hide rows base on value

    I've used the following code to hide columns based on a value in a cell. It works great. Range("E:CF").EntireColumn.Hidden = False Dim c As Range For Each c In Range("E3:CF3").Cells If c.Value = "0" Then c.EntireColumn.Hidden = True End If Next c I...
  13. M

    For Each - Invalid Range

    I'm trying to use a For Each macro to erase dates in a range that are greater than Today. The range is C3 and D3 to Lr (I have Lr set earlier in the macro and it works other places for the same purpose). I keep getting an invalid range when I use: Dim c As Range For Each c In...
  14. T

    Dates converting to American format when using CDATE?

    Hi all, I have an issue with the code below where I am attempting to amend incorrectly formatted dates so any instance of "." should change to "/". The first piece of code seems to convert everything incorrectly: Sub DateConv() Dim LrDst As Long Dim DstSht As Worksheet Dim...
  15. Nelson78

    VBA and Excel: sporadic error 91 in grasping huge quantity of datas from the web

    Hello everybody. I've been grasping a lot of data from a website via Excel using the following code. Dim tbls, tbl, trs, tr, tds, td, R, c Set tbls = IE.document.getElementsByTagName("table") For R = 0 To tbls.Length - 1...
  16. S

    Months of Coverage

    Today I use this function to calculate months of coverage =coverage(Cell that holds inventory, range of cells that have the monthly forecast) =coverage(F7,G5:I5) I want to use a function that does the same thing, but with value in the function such as : =coverage(1000,500,250,150,50)...
  17. S

    VBA to limit the loop

    Hi, I am trying to create a VBA which will search a numeric number as given in excel in PDF and extract the pages. Code is working fine but rather is very slow. It seems on below line it loops many time. How to limit this? As my search limit on 14 count only where it finds the value. For...
  18. P

    VBA Question -Where is the source data

    Hi, am looking at a former colleagues spreadsheet, and I am trying to determine where h data is company is? But am at a complete lost???? please help, code is below: Sub Fileoutput() ' Applies combination of corrections and successfull lookup data into format ready for upload Dim C, D...
  19. P

    Conditional Formatting - (Range)

    Hi Have a conditional formatting code <Code> Sub FormatTotalRow() 'Worksheets(1).Range("K1:K500").Select 'For Each c In Selection.Cells 'If c.Value = "CHECK" Then c.Resize(1).Interior.ColorIndex = 50 'Next c Worksheets(1).Range("K1:K500").Select For Each c In Selection.Cells If c.Value >= 350...
  20. B

    Script Dictionary - Item

    I have the below code which adds the desired sheets from Column A. My question is the understanding on the "Nothing". My attempt to interpret is this is related to an item reference, in this case not necessary therefore the "Nothing" Thank You for any explanation..... <colgroup><col...

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