title: VBA - Check if a cell's content is bold
body: <p>I'm currently trying to create a calendar in Excel using VBA.<br>
  Now I need to check if a cell in column B is formatted bold. Due the fact that the line which is formatted bold can change its position, I need to check every single cell in column B, if its content is bold.<br>
  <br>
  My current code:</p>
  
  <pre><code>Sub ScanBlock1()
  
  Dim Zelle As Integer
  Dim Cell As String
  Dim found As Integer
  
  Zelle = 7
  Zell = "B" &amp; Zelle
  found = 0
  
  'CopyCat.OpenCopyCat
  Windows("Preset.xlsm").Activate
  
  Do While found = 0
      Windows("Preset.xlsm").Activate
      Range(Zell).Select
      If Range(Zell).Font.Bold Then
          'Save start and end for copycat
          found = 1
      Else
          Zelle = Zelle + 2
      End If
  Loop
  
  End Sub
  </code></pre>
  
  <p>While trying this, I ran in to multiple problems.
  <br><br>
  First problem I have is, Excel just won't automatically activate the requested window. I don't know why. It worked all the time in other projects.
  <br><br>
  Second problem: I always get an overflow error in my <code>IF</code> Statement.
  I think that it's caused by Excel not activating my requested window.<br>
  EDIT: Because many people already wrote that it is an overflow error because NO BOLD CELL IS FOUND, the window I'd like to open/select is "full" of bold cells.
  <br></p>