fork download
  1. Dim bInUndoRedo AsBooleanPrivateSub ThisDocument_ContentControlBeforeDelete(ByVal OldContentControl As Microsoft.Office.Interop.Word.ContentControl, ByVal InUndoRedo AsBoolean) HandlesMe.ContentControlBeforeDelete
  2. bInUndoRedo = InUndoRedo
  3. EndSubPrivateSub ThisDocument_SelectionChange(ByVal sender AsObject, ByVal e As Tools.Word.SelectionEventArgs) HandlesMe.SelectionChange
  4.  
  5. TryDim selection As Word.Selection = e.Selection
  6. IfNot bInUndoRedo ThenDim numberOfControls AsInteger = (From book As Word.Bookmark In selection.Bookmarks _
  7. Select book _
  8. Where book.Name.Contains("Something")).Count()
  9. EndIfDim s AsString, bkm As Word.Bookmark
  10. ForEach bkm In selection.Bookmarks
  11. s = bkm.Name
  12. If s.Contains("Something") ThenExitForNextCatch ex As Exception
  13.  
  14. MsgBox(ex.Message)
  15.  
  16. EndTryEndSub
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
Visual Basic.Net Compiler version 0.0.0.5914 (Mono 2.4.2 - r)
Copyright (C) 2004-2008 Rolf Bjarne Kvinge. All rights reserved.


/home/c7jbWc/prog.vb (1,5) : Error VBNC30203: Not valid as identifier.
/home/c7jbWc/prog.vb (2,24) : Error VBNC30203: Not valid as identifier.
/home/c7jbWc/prog.vb (3,27) : Error VBNC30203: Not valid as identifier.
/home/c7jbWc/prog.vb (5,19) : Error VBNC30203: Not valid as identifier.
/home/c7jbWc/prog.vb (6,20) : Error VBNC30203: Not valid as identifier.
/home/c7jbWc/prog.vb (9,23) : Error VBNC30203: Not valid as identifier.
/home/c7jbWc/prog.vb (10,22) : Error VBNC30203: Not valid as identifier.
/home/c7jbWc/prog.vb (11,18) : Error VBNC30203: Not valid as identifier.
/home/c7jbWc/prog.vb (12,19) : Error VBNC30203: Not valid as identifier.
/home/c7jbWc/prog.vb (14,21) : Error VBNC30203: Not valid as identifier.
/home/c7jbWc/prog.vb (16,25) : Error VBNC30203: Not valid as identifier.
There were 11 errors and 0 warnings.
Compilation took 00:00:00.6046630
stdout
Standard output is empty