+ Reply to Thread
Results 1 to 4 of 4

Run vba code, try to type on active sheet, it puts on different sheet

  1. #1
    Forum Contributor
    Join Date
    10-12-2012
    Location
    Bournemouth
    MS-Off Ver
    Excel 2010 / Excel 2007
    Posts
    126

    Run vba code, try to type on active sheet, it puts on different sheet

    Hi all

    I have created the attached document, and the problem I am having is when the New QPR Form button is pressed - after the job information is input, it opens a tab for the user to input data.

    However, if you try to type, it inputs the data into the Tools tab, rather than the form - the only way round this is to click on tools, then on New QPR tab and it works fine.

    So, I try to allow for this in the code, but it hasn't worked - does anyone know how to solve this?OA Planner.xlsm

  2. #2
    Forum Contributor Jack7774's Avatar
    Join Date
    08-31-2012
    Location
    Georgia, US
    MS-Off Ver
    Excel 2010
    Posts
    576

    Re: Run vba code, try to type on active sheet, it puts on different sheet

    I think I deleted the line of code you were having trouble with try again.

    Just in case it was the sheets("tools").select line in this section below

    Please Login or Register  to view this content.
    Attached Files Attached Files
    Thank those who have helped you by clicking the Star * below their name and please mark your post [SOLVED] if it has been answered satisfactorily.

  3. #3
    Forum Contributor
    Join Date
    10-12-2012
    Location
    Bournemouth
    MS-Off Ver
    Excel 2010 / Excel 2007
    Posts
    126

    Re: Run vba code, try to type on active sheet, it puts on different sheet

    Thanks for looking Jesse - unfortunately still the same problem though - also just realised I should have specified - I am using Excel 2013 - this was originally written in 2007 (and worked fine) - but I then found out it needed to be in 2013 - I need to make some changes to conditional formatting, but all the other code works fine, expect the DQPRFORM sub, which has the issue with writing to the tools tab when you try and fill in the Y/N boxes

  4. #4
    Forum Contributor
    Join Date
    10-12-2012
    Location
    Bournemouth
    MS-Off Ver
    Excel 2010 / Excel 2007
    Posts
    126

    Re: Run vba code, try to type on active sheet, it puts on different sheet

    For any of those having a similar problem, I have managed to fix this.

    What the form was doing was calling a userform for the job number, then openeing the orm to complete, then after pressing submit it would create it for that job.

    Now what it is doing, is doing it the other way round - opens the blank form first, then calls the userform - this way round, works perfectly. Not sure why, but hey ho!
    If my answer helped pls click the star =)

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Code adds data to active sheet instead of specified sheet.
    By Nitefox in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-12-2014, 11:45 AM
  2. [SOLVED] Active sheet shifts back to original sheet when executing code
    By pcdog in forum Excel Programming / VBA / Macros
    Replies: 20
    Last Post: 10-22-2012, 11:07 AM
  3. [SOLVED] How to get (range)macro to always run code on a specific sheet regardless of active sheet?
    By JTwrk in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-18-2012, 04:33 PM
  4. Delete Specific type of chart from active sheet
    By Macdave_19 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-20-2009, 06:42 AM
  5. How do i copy a active sheet to a new sheet with code and everything
    By Karill in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-11-2006, 01:22 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1