I've got a excel workbook that i need to be able to automate standard info into via a form, most of the code ive seen online so far is nice a easy, but they all have a similar theme, for the data to import at the bottom of the sheet, where as i would prefer the information to populate at the top.
should be easy enough... but i'm hitting a brick wall. heres what i have so far.
the only code that works is the insert row and user form initialise, the rest doesnt work at all.
Private Sub UserForm_Initialize()
Dim Cbranch As Range
Dim cbar As Range
Dim br As Worksheet
Set br = Worksheets("Branch list")
For Each Cbranch In br.Range("BARList")
.List(.ListCount - 1, 1) = Cbranch.Offset(0, 1).Value
For Each cbar In br.Range("BRstatus")
Private Sub cmdOk_Click()
Dim Cname As Long
Dim Cstatus As Long
Dim Cday As Long
Dim Cbranch As Long
Dim Cchange As Long
Selection.Insert Shift:=xlDown, CopyOrigin:=xlFormatFromLeftOrAbove
Cname = txtname.Value.Cells("A3", 0)
Cstatus = CmbStatus.Value.Cells("B3", 0)
Cday = txtday.Value.Cells("C3", 0)
Cbranch = cmbBranch.Value.Cells("E3", 0)
Cchange = txtchange.Value.Cells("F3", 0)