LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 193
Default Excel Form for updating records

Hi Guys
I need a form to let me update records in Excel 2002 I have a form thats
lets me enter a new record see code below but I don't know how to update the
records I have entered already
As you can see I can't use the Automatic form ie Data Forms, Excel gives
me as I have two combo boxes on it
Also I would like to use the scroll option to scroll through these records
Thanks so much Terry

Private Sub CommandButton1_Click()
Dim LastRow As Object

Set LastRow = Sheet1.Range("a65536").End(xlUp)

LastRow.Offset(1, 0).Value = Program.Text
LastRow.Offset(1, 2).Value = Catagory.Text
LastRow.Offset(1, 3).Value = Description.Text
LastRow.Offset(1, 4).Value = DiskType.Text
LastRow.Offset(1, 5).Value = DiskNumber.Text
LastRow.Offset(1, 6).Value = BackupDrive.Text
LastRow.Offset(1, 7).Value = Version.Text
LastRow.Offset(1, 8).Value = DiskName.Text
LastRow.Offset(1, 9).Value = Key.Text
LastRow.Offset(1, 10).Value = Note.Text



MsgBox "One record written to Software"

response = MsgBox("Do you want to enter another record?", _
vbYesNo)

If response = vbYes Then
Program.Text = ""
Catagory.Text = ""
Description.Text = ""
DiskType.Text = ""
DiskNumber = ""
BackupDrive.Text = ""
Version.Text = ""
DiskName.Text = ""
Key.Text = ""
Note.Text = ""


Program.SetFocus

Else
Unload Me
End If


End Sub

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Updating Listbox in Excel Form Sue[_2_] Excel Programming 0 February 7th 08 04:40 AM
Updating Listbox in Excel Form Sue[_2_] Excel Programming 0 February 7th 08 04:40 AM
Adding/Updating Records in Access with Excel BCLivell Excel Programming 5 June 14th 07 09:56 PM
Add & Delete Records in Excel using a form showing a scrollbar also! eijaz Excel Programming 1 October 26th 03 05:31 PM
Access records updating from Excel. Dirk Batenburg Excel Programming 2 October 8th 03 03:06 PM


All times are GMT +1. The time now is 01:19 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"