+ Reply to Thread
Results 1 to 8 of 8

Auto_open macro in excel 2003

  1. #1
    Registered User
    Join Date
    06-10-2010
    Location
    Brunei
    MS-Off Ver
    Excel 2003
    Posts
    5

    Auto_open macro in excel 2003

    Hi,
    I want to create a macro in VB to automatically pop-up message once the excel file is open based on some criteria.

    Attach is the sample excel workbook i'm working on. I want the macro to pop-up msg to alert user on the target date, etc., automatically once the workbook is open.
    Criteria e.g. if the actual feedback is blank, if the target feedback date is greater than today's date, then msg "Exceed target feedback, Pls action accordingly".

    I've created the scripts but it doesn't seems to work.
    Please Login or Register  to view this content.
    Fyi, i'm using MS Excel 2003. Your advise is highly appreciated.
    Ain
    Attached Files Attached Files
    Last edited by royUK; 06-24-2010 at 01:03 AM.

  2. #2
    Forum Expert Domski's Avatar
    Join Date
    12-14-2009
    Location
    A galaxy far, far away
    MS-Off Ver
    Darth Office 2010
    Posts
    3,950

    Re: Auto_open macro in excel 2003

    Try:

    Please Login or Register  to view this content.

    Dom
    "May the fleas of a thousand camels infest the crotch of the person who screws up your day and may their arms be too short to scratch..."

    Use code tags when posting your VBA code: [code] Your code here [/code]

    Remember, saying thanks only takes a second or two. Click the little star to give some Rep if you think an answer deserves it.

  3. #3
    Forum Contributor pierre08's Avatar
    Join Date
    02-16-2010
    Location
    Paris
    MS-Off Ver
    Excel 2003
    Posts
    166

    Re: Auto_open macro in excel 2003

    Put your code in a tags "
    Please Login or Register  to view this content.
    " with this it will be more easier to use the code.

    I think this isn't working because in case of your condition is not respected it dosen't do anything:

    Please Login or Register  to view this content.
    Hope this helps

  4. #4
    Registered User
    Join Date
    06-10-2010
    Location
    Brunei
    MS-Off Ver
    Excel 2003
    Posts
    5

    Re: Auto_open macro in excel 2003

    Hi,
    I have try using this codes, it works perfectly when i dry run. Many thanks for that. But when i open the excel file, it doesn't automatically pop-up the message, i need to manually run the macro.

    Furthermore, when there's going to be more than one cell, how do i change the codes to accomodate all D cells and G cells to be check to prompt the alert whenever the today's date is greather than the target date. I'm stuck here.

    Your advise is highly appreciated.

  5. #5
    Forum Expert Domski's Avatar
    Join Date
    12-14-2009
    Location
    A galaxy far, far away
    MS-Off Ver
    Darth Office 2010
    Posts
    3,950

    Re: Auto_open macro in excel 2003

    Have you placed the code on the ThisWorkbook code page? It won't run automatically when the file is opened if not.

    Can you post the code you now have (remember to use code tags).

    Dom

  6. #6
    Registered User
    Join Date
    06-10-2010
    Location
    Brunei
    MS-Off Ver
    Excel 2003
    Posts
    5

    Re: Auto_open macro in excel 2003

    Hi Dom,

    It works fine now, i've used a macro, instead of putting the codes using VBA. Sorry for that.
    This are the codes i have right now.

    Please Login or Register  to view this content.
    In this code, there is only 2 cells i used. Is there any codes that i can use to declare all cells in column D and column G to be check whenever the today's date is greater than the target date, so that pop-up message will appear to alert me. I find it hard to codes if i have to declare all cells in column D and column G. Is there any other ways that is more easier than this pop-up message alert? Is there any codes that i can use just to change the color of the cell to red or green or blue?


    Rgds
    Ain

  7. #7
    Registered User
    Join Date
    06-10-2010
    Location
    Brunei
    MS-Off Ver
    Excel 2003
    Posts
    5

    Re: Auto_open macro in excel 2003

    Hi All,

    Thank you for all your advice. I have managed to complete my codes but are still having some porblems, not same as this one. Therefore, i want to close this thread and will post a new thread based on the new issue i need helps on.

    I thanked you for all the help and advice in this subject. Hope we'll see again in other thread/subject..

    Rgds,
    Ain

  8. #8
    Forum Contributor pierre08's Avatar
    Join Date
    02-16-2010
    Location
    Paris
    MS-Off Ver
    Excel 2003
    Posts
    166

    Re: Auto_open macro in excel 2003

    Glad that helped. Pl. edit your first post and mark it as solved.

    Thanks

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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