VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,580 questions
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
I am trying to select a column and next to it have the years show up. Copy this VBA code but not sure exactly if it will translate to VB.net
Columns("C:C").Select
Selection.NumberFormat = "m/d/yyyy"
Range("C2").Select
ActiveCell.FormulaR1C1 = "11/2/2020"
Columns("D:D").Select
Selection.Insert Shift:=xlToRight, CopyOrigin:=xlFormatFromLeftOrAbove
Range("D2").Select
Application.CutCopyMode = False
ActiveCell.FormulaR1C1 = "=YEAR(RC[-1])"
Columns("D:D").Select