hi
i read in values from an excel spread sheet like this
and display them in another spreadsheet using this
now what i want to do is take the value from the first block of code and take it away from the second one and display it in the spreadsheet but can seem to get it working.
was trying something like this but it doesnt work
anyone any ideas how to get the value when they are taken away
i read in values from an excel spread sheet like this
Code:
oRng = oWSSheet.Cells.Find("CASH (12000000)", , _
Excel.XlFindLookIn.xlValues, Excel.XlLookAt.xlPart, _
Excel.XlSearchOrder.xlByRows, Excel.XlSearchDirection.xlNext, False)
' MsgBox("Value '" & oRng.Value & "' found at '" & oRng.Address)
Me.cash1 = oRng.Offset(0, 5).Value
oRng = Nothing
oRng = oWSSheet.Cells.Find("Cash at Bank - URGL", , _
Excel.XlFindLookIn.xlValues, Excel.XlLookAt.xlPart, _
Excel.XlSearchOrder.xlByRows, Excel.XlSearchDirection.xlNext, False)
' MsgBox("Value '" & oRng.Value & "' found at '" & oRng.Address)
Me.cash2 = oRng.Offset(0, 5).Value
oRng = Nothing
Code:
oBook.Worksheets(1).Cells(30, 3).value = _cash1
was trying something like this but it doesnt work
Code:
Me.Cash = Me.cash1 = oRng.Offset(0, 5).Value - Me.cash2 = oRng.Offset(0, 5).Value