Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
hi,
having problems with this part of my function to open a new worksheet if it's the first time it executes, and then write a new row. and all subsequent times I execute it, it will write in another new row of info. All help appreciated!! Thanks --- Message posted from http://www.ExcelForum.com/ |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() Private wksMyNewSheet As Worksheet Sub test() Dim i As Long If wksMyNewSheet Is Nothing Then Set wksMyNewSheet = Worksheets.Add wksMyNewSheet.Name = "My New Sheet" End If With wksMyNewSheet With .UsedRange On Error Resume Next i = 1: i = .Find("*", .Cells(1), xlFormulas, xlWhole, xlByRows, xlPrevious).Row + 1 On Error GoTo 0 End With .Cells(i, 1).Value = "New Entry: " & Format(Now(), "hh:mm:ss") End With End Sub -- Rob van Gelder - http://www.vangelder.co.nz/excel "junx13 " wrote in message ... hi, having problems with this part of my function to open a new worksheet if it's the first time it executes, and then write a new row. and all subsequent times I execute it, it will write in another new row of info. All help appreciated!! Thanks --- Message posted from http://www.ExcelForum.com/ |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Need Macro to create a new worksheet and insert image | Excel Discussion (Misc queries) | |||
Cannot insert worksheet in exel - not available in insert menu | Excel Worksheet Functions | |||
Unable to Insert Worksheet/Move and copy worksheet Excel 2003 | Excel Worksheet Functions | |||
How to create a form to insert a hyerlink.VBA code to create a for | Excel Discussion (Misc queries) | |||
Can I auto insert a worksheet when I insert a value in a cell. | Excel Worksheet Functions |