+ Reply to Thread
Results 1 to 8 of 8

Need a Macro that enters a score if the correct conditions are met (File Attached)

  1. #1
    Valued Forum Contributor unit285's Avatar
    Join Date
    10-29-2015
    Location
    TN
    MS-Off Ver
    Office 365
    Posts
    358

    Need a Macro that enters a score if the correct conditions are met (File Attached)

    Hello VBA Guru's
    I am working on a project that is way over my head atm. I will attach the file below.
    Basically I want the Red "Enter Score" button to post the Score Results located in K30 into the correct cell, of the sheet that matches the criteria set on the "Quick_Test" Sheet. Quick_Test!M7 needs to be matched up with B2 in 11 possible sheets named Subject1 thru Subject11.

    Once the correct Sheet is located, then the criteria set in Quick_Test should decide where the contents of Quick_Test!K30 should be pasted. And the contents of Quick_Test!K30 are formatted as a Percentage, but they need to be pasted into the Subject Sheets as a Number. So 90% should be pasted as 90, not as .9

    Any help is greatly appreciated!

    Quick_Test.xlsm

  2. #2
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Need a Macro that enters a score if the correct conditions are met (File Attached)

    Exactly where should that score be posted?
    If I've helped you, please consider adding to my reputation - just click on the liitle star at the left.

    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~(Pride has no aftertaste.)

    You can't do one thing. XLAdept

    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~aka Orrin

  3. #3
    Valued Forum Contributor unit285's Avatar
    Join Date
    10-29-2015
    Location
    TN
    MS-Off Ver
    Office 365
    Posts
    358

    Re: Need a Macro that enters a score if the correct conditions are met (File Attached)

    Quote Originally Posted by xladept View Post
    Exactly where should that score be posted?
    Thanks for replying,

    On the Quick_Test Sheet Cells D7, M7, D11, I11, M11, and O11 set criteria which sets where K30 should be copied to. So if Quick_Test!M7 says "Math 1" then the macro uses that to find the correct sheet by matching Quick_Test!M7 with (In my example) Subject1!B2.
    Once the correct sheet is found, then it should match Quick_Test!D7 with Subject1!A:A to find the correct row, (in my example row Subject1!A9)
    Then it should match Quick_Test!I11 with Subject1!B9 or Subject1!B10 because they are merged, This pinpoints the exact row.
    Then it should match Quick_Test!M11 with Subject1!E2:BF2 to find which Week
    Then it should match Quick_Test!O11 with Row 3 in Subject1 in the Week Section chosen by Quick_Test!M11.

    In my attached sheet, Quick_Test criteria would point to paste Quick_Test!K30 in Subject1!G10

    I hope I'm making sense.

    Thanks!
    Last edited by unit285; 12-04-2015 at 09:54 PM.

  4. #4
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Need a Macro that enters a score if the correct conditions are met (File Attached)

    That's what I needed to know - I'll attempt it tomorrow

  5. #5
    Forum Contributor
    Join Date
    09-28-2014
    Location
    harbin,china
    MS-Off Ver
    2007
    Posts
    162

    Re: Need a Macro that enters a score if the correct conditions are met (File Attached)

    Hi, unit

    Try this
    Attached Files Attached Files

  6. #6
    Valued Forum Contributor unit285's Avatar
    Join Date
    10-29-2015
    Location
    TN
    MS-Off Ver
    Office 365
    Posts
    358

    Re: Need a Macro that enters a score if the correct conditions are met (File Attached)

    Hello simcode,

    Your copy seems like it might work. I will test it further tomorrow. I must ask however, is
    Please Login or Register  to view this content.
    the entirety of the code for this macro? If so my mind is blown lol.. cause it seemed like a pretty comprehensive criteria for such a short solution :D
    But I am a complete novice at VBA so yeah..

    Thanks!

  7. #7
    Forum Contributor
    Join Date
    09-28-2014
    Location
    harbin,china
    MS-Off Ver
    2007
    Posts
    162

    Re: Need a Macro that enters a score if the correct conditions are met (File Attached)

    Nope, see Module1, the most of the code is in it.

    You are welcome.

  8. #8
    Valued Forum Contributor unit285's Avatar
    Join Date
    10-29-2015
    Location
    TN
    MS-Off Ver
    Office 365
    Posts
    358

    Re: Need a Macro that enters a score if the correct conditions are met (File Attached)

    Simcode I believe this copy is Perfect! Thankyou so much!!

+ 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] Want to Auto Report of attached file using Macro VBA
    By Mohsin Kodvavi in forum Excel Programming / VBA / Macros
    Replies: 15
    Last Post: 08-04-2015, 11:40 AM
  2. [SOLVED] Macro to select the correct border and fill the cells white. VBA Attached
    By anthony.maddick in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 10-13-2014, 07:41 PM
  3. Macro to sort attached file
    By Benjamin2008 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-09-2010, 01:15 AM
  4. Comparison:get a correct score
    By :-) in forum Excel General
    Replies: 7
    Last Post: 02-18-2010, 10:12 AM
  5. Macro for checking multiple conditions & selecting the correct range
    By ashwin_pr in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-25-2007, 09:53 PM
  6. [SOLVED] How do I make all VBA routines offlimits until a user enters the correct password
    By Kevin H. Stecyk in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 01-23-2005, 03:06 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