I am of the old school that adheres to the KISS principle. It appears that you try to overcomplicate your code. I am available for custom excel projects at only $75 hourly
Sub ViewLogFirstSAS() With Sheets("form") .Select Sheets("RoomReservation").Cells(7, 3).Resize(, 18).Copy .Range("d5").PasteSpecial Paste:=xlPasteValues, Transpose:=True Application.CutCopyMode = False .Range("d8").Select End With End Sub ======== or even simpler since you are already on Sheets(“form”) Sub ViewLogFirstSAS()’ use this With Range("d5") Sheets("RoomReservation").Cells(7, 3).Resize(, 18).Copy .PasteSpecial Paste:=xlPasteValues, Transpose:=True .Offset(3).Select End With End Sub ===== Don Guillett SalesAid Software dguille...@gmail.com From: Christopher Kevin Sent: Monday, January 16, 2012 7:00 PM To: excel-macros@googlegroups.com Subject: Re: $$Excel-Macros$$ Previous and Next Buttons on Excel Sheet! Help Please I cannot delete rows on the source sheet I'm based in Port Moresby and my old man (dad) has a small guest house that he is renting out to his guests that I went to help him do it using excel Regards Chris On Tue, Jan 17, 2012 at 10:46 AM, dguillett1 <dguille...@gmail.com> wrote: Didn’t get a chance to fully look at it but have you tried simply deleting rows on the source sheet? Shutting down. Where are you and what is this for? Don Guillett SalesAid Software dguille...@gmail.com From: Christopher Kevin Sent: Monday, January 16, 2012 6:17 PM To: excel-macros@googlegroups.com Subject: Re: $$Excel-Macros$$ Previous and Next Buttons on Excel Sheet! Help Please Don, OK I'll try to explain it more clearly: As per the file attached: 1) Data is entered into the "RoomReservations" Sheet using the "Form" Sheet as an excel userform. This "Form" Sheet contains the Following Fields as shown below: Booking Ref Ref001 Guest First Name Chris Guest Surname Kevin Guest Phone No 309 0478 Guest Email Address cke...@gmail.com Guest Country PNG Check In Date 15/01/2012 Check Out Date 17/01/2012 Adult Guests 2 Children Guests 2 Room Type Suite Room No 601 Booking Status Confirmed No of Nights 2 Rate 350 % Discount 0.25 Total Payment 700 Remarks Paid 2) After entering the data the "Add Bookings" button on the "Form" Sheet is clicked to transfer the data from the "Form"Sheet to the "RoomReservation" Sheet. The Headers start at row 6. The first entry is added to row 7. 3) To view previously added bookings the the following bottons on the "Form" Sheet are clicked. "<< first record", "<previous record", ">next record", "last record>>" .This brings up or populates the previous record from the "RoomReservation" Sheet to the "Form" Sheet for viewing 4) When I click on the the "<< first record" button it goes beyond row7 to row 1, showing blanks cells on the "Form" Sheet and not row 7. What I want is, when I click on the "<< first record" button, record on row 7 to show on the "Form" Sheet instead of going to row 1 and showing blank cells. 5) When I click on the the "< previous record" button it goes beyond row 7, row 6, row 5 etc, etc, to row 1. What I want is, when I click on the "<previous record" button, view records untill row 7 and not row 6 etc, etc to row 1. 6) To get to the field of it try clicking these buttons to see how it works currently. Please refeer to the attached file. I hope I have explained myself clearly and thanks you once again in advance for any help that I may recieve. On Tue, Jan 17, 2012 at 9:08 AM, dguillett1 <dguille...@gmail.com> wrote: Can you re-explain what you want. Perhaps with an example of what it should look like. Don Guillett SalesAid Software dguille...@gmail.com From: Christopher Kevin Sent: Monday, January 16, 2012 4:13 PM To: excel-macros@googlegroups.com Subject: Re: $$Excel-Macros$$ Previous and Next Buttons on Excel Sheet! Help Please Don, Thank you for the help but it does'nt work. Regards Chris On Tue, Jan 17, 2012 at 4:46 AM, dguillett1 <dguille...@gmail.com> wrote: Does this help? .Rows("12:22").Hidden = True Don Guillett SalesAid Software dguille...@gmail.com From: Christopher Kevin Sent: Sunday, January 15, 2012 4:16 PM To: excel-macros@googlegroups.com Subject: $$Excel-Macros$$ Previous and Next Buttons on Excel Sheet! Help Please Can you experts help me with my problem? What I want is: When the previous < button is clicked, I want only records up untill row 7 to show on the Form Sheet as per the attached Room Reservation Sheet. And the same should be applied to the go to last record << button. That is I want row 7 to be the last row and not going back beyond row 7 to row 1. How can that be done as per the attached file? The that I currently have is included in file. Additional Explaination: When I clcik the << and < buttons, column headers and blank rows above row 7 are also populated on to the Form. How can this be avoided? I hope I have explained myself clearly. Thank you all you experts in advance for any help that may be provided. Chris -- FORUM RULES (986+ members already BANNED for violation) 1) Use concise, accurate thread titles. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get quick attention or may not be answered. 2) Don't post a question in the thread of another member. 3) Don't post questions regarding breaking or bypassing any security measure. 4) Acknowledge the responses you receive, good or bad. 5) Cross-promotion of, or links to, forums competitive to this forum in signatures are prohibited. NOTE : Don't ever post personal or confidential data in a workbook. Forum owners and members are not responsible for any loss. ------------------------------------------------------------------------------------------------------ To post to this group, send email to excel-macros@googlegroups.com -- FORUM RULES (986+ members already BANNED for violation) 1) Use concise, accurate thread titles. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get quick attention or may not be answered. 2) Don't post a question in the thread of another member. 3) Don't post questions regarding breaking or bypassing any security measure. 4) Acknowledge the responses you receive, good or bad. 5) Cross-promotion of, or links to, forums competitive to this forum in signatures are prohibited. NOTE : Don't ever post personal or confidential data in a workbook. Forum owners and members are not responsible for any loss. ------------------------------------------------------------------------------------------------------ To post to this group, send email to excel-macros@googlegroups.com -- FORUM RULES (986+ members already BANNED for violation) 1) Use concise, accurate thread titles. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get quick attention or may not be answered. 2) Don't post a question in the thread of another member. 3) Don't post questions regarding breaking or bypassing any security measure. 4) Acknowledge the responses you receive, good or bad. 5) Cross-promotion of, or links to, forums competitive to this forum in signatures are prohibited. NOTE : Don't ever post personal or confidential data in a workbook. Forum owners and members are not responsible for any loss. ------------------------------------------------------------------------------------------------------ To post to this group, send email to excel-macros@googlegroups.com -- FORUM RULES (986+ members already BANNED for violation) 1) Use concise, accurate thread titles. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get quick attention or may not be answered. 2) Don't post a question in the thread of another member. 3) Don't post questions regarding breaking or bypassing any security measure. 4) Acknowledge the responses you receive, good or bad. 5) Cross-promotion of, or links to, forums competitive to this forum in signatures are prohibited. NOTE : Don't ever post personal or confidential data in a workbook. Forum owners and members are not responsible for any loss. ------------------------------------------------------------------------------------------------------ To post to this group, send email to excel-macros@googlegroups.com -- FORUM RULES (986+ members already BANNED for violation) 1) Use concise, accurate thread titles. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get quick attention or may not be answered. 2) Don't post a question in the thread of another member. 3) Don't post questions regarding breaking or bypassing any security measure. 4) Acknowledge the responses you receive, good or bad. 5) Cross-promotion of, or links to, forums competitive to this forum in signatures are prohibited. NOTE : Don't ever post personal or confidential data in a workbook. Forum owners and members are not responsible for any loss. ------------------------------------------------------------------------------------------------------ To post to this group, send email to excel-macros@googlegroups.com -- FORUM RULES (986+ members already BANNED for violation) 1) Use concise, accurate thread titles. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get quick attention or may not be answered. 2) Don't post a question in the thread of another member. 3) Don't post questions regarding breaking or bypassing any security measure. 4) Acknowledge the responses you receive, good or bad. 5) Cross-promotion of, or links to, forums competitive to this forum in signatures are prohibited. NOTE : Don't ever post personal or confidential data in a workbook. Forum owners and members are not responsible for any loss. ------------------------------------------------------------------------------------------------------ To post to this group, send email to excel-macros@googlegroups.com -- FORUM RULES (986+ members already BANNED for violation) 1) Use concise, accurate thread titles. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get quick attention or may not be answered. 2) Don't post a question in the thread of another member. 3) Don't post questions regarding breaking or bypassing any security measure. 4) Acknowledge the responses you receive, good or bad. 5) Cross-promotion of, or links to, forums competitive to this forum in signatures are prohibited. NOTE : Don't ever post personal or confidential data in a workbook. Forum owners and members are not responsible for any loss. ------------------------------------------------------------------------------------------------------ To post to this group, send email to excel-macros@googlegroups.com -- FORUM RULES (986+ members already BANNED for violation) 1) Use concise, accurate thread titles. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get quick attention or may not be answered. 2) Don't post a question in the thread of another member. 3) Don't post questions regarding breaking or bypassing any security measure. 4) Acknowledge the responses you receive, good or bad. 5) Cross-promotion of, or links to, forums competitive to this forum in signatures are prohibited. NOTE : Don't ever post personal or confidential data in a workbook. Forum owners and members are not responsible for any loss. ------------------------------------------------------------------------------------------------------ To post to this group, send email to excel-macros@googlegroups.com