title: paste special in vba
body: <p>i am trying to use pastespecial in vba..i basically need to paste the values (and not the formulas as the formula gets recalculated while pasting to the new sheet because of change in the cell values in that sheet) to another sheet...But i am getting error 1004 saying 'aaplication defined or object defined error'..heres the code...please help somebdy...</p>
  
  <pre><code>Sub Macro1try()
  
  Dim i As Integer
  
  Dim j As Integer
  
  For i = 1 To 2
  
  Worksheets("Volatility").Cells(1, "B").Value = Worksheets("Volatility").Cells(i, "S").Value
  
  Call mdlMain.ExtractData
  
   Range("A11:D2330").Select
  
      Selection.Copy
  
      Sheets.Add After:=Sheets(Sheets.Count)
  
      ActiveSheet.PasteSpecial Paste:=xlPasteValuesAndNumberFormats, Operation:= _
          xlNone, SkipBlanks:=False, Transpose:=False
  
  
    ActiveWorkbook.Sheets("Volatility").Activate
  
  
      Next i
  End Sub
  </code></pre>