Macro Help

Dear Macro Experts
I wrote this macro
IF KF2 in period 4
>
Average of KF2 from period 1 to 3,
Action
POP UP a message individually for each period beginning period 4.
ENDIF
That works
but here is what I experience
I need to click on the information message box a dozen times before I can save the value in KF2 for period 4
I need to click on the information message box a dozen times even though the value is only entered in period 4.
What is wrong and how to fix this ?
e.g. in the above case since I ONLY entered a value in period 4, the message box should vanish on one click of check mark. Why do I need to click 10 times ?
Thanks
BS

Wow. I pretended to figure out but I can't.
Another learning after a decade that dragging this text file to a dialog box starts debugger. So much hidden knowledge out there. Much un-SAP like thingy. May I ask how did you manage to learn all this? by reading help documentation ? or attending secret "SAP Internal" privileged training classes not available to most ?
My syntax is what I wrote above. I have to click so many remaining number of periods in the future time series even though the condition above is not met for remaining periods. e.g. period 5, 6, 7......but I think I can add the IS_BLANK and ELSE statements too. The semantic check says nothing is wrong with this macro!
Thanks
BS

Similar Messages

  • Macro Help book for SCM7.0

    Hi expert
    I am looking for SCM7.0 macro help book for upgrading SCM4.0 to SCM7.0.
    If anyone have book, please let me know.
    Best regards
    Hinoki from JAPAN with love

    Hi,
    There is an OSS note  which may partially help you.
    539797  Collective Consulting Note on Macros  .
    Please check this.
    Regards
    Datta

  • Macro help: Nav Attribute Value

    Dear Macro Gurus,
    I need to realize this
    IF the value of the Navigational Attribute "NavChar2" of a POS "Char1" is = a, b, and c
    then
    do something.
    ENDIF
    I could do the something
    but couldn't get the macro function right for the IF.
    Help appreciated
    Thanks
    BS

    Is this any help?  Function ACT_IOBJNM_VALUE with a double underscore to separate the characteristic from its nav attribute.
    ACT_IOBJNM_VALUE( 'characteristic__navattr' ) = 'X'
    which could be implemented in macro similar to attachment

  • Excel Macro Help - SendKeys

    I hope this is the right forum - sorry if it's not. I'm working with Excel Macros. Having a few problems adjusting to Mac from PC. I want to do a send key type command to close a web window (command F4). In my PC, the command was:
        Application.SendKeys "%({F4})"
    I'd like to do a send key type command on the mac for "command+F4".
    I have no idea what I'm doing - I admit, but I've basically successfully pieced together bits and pieces of help from various web sources and made some macros that do what I need. This is one I haven't been able to figure out.
    Thank you so much and again, I'm a newbie, so be kind! Thanks :-)
    Kat

    bump *

  • SAP Record Macro Help

    Hello all,
    I am not sure how we can use loop.
    If Not IsObject(application) Then
       Set SapGuiAuto  = GetObject("SAPGUI")
       Set application = SapGuiAuto.GetScriptingEngine
    End If
    If Not IsObject(connection) Then
       Set connection = application.Children(0)
    End If
    If Not IsObject(session) Then
       Set session    = connection.Children(0)
    End If
    If IsObject(WScript) Then
       WScript.ConnectObject session,     "on"
       WScript.ConnectObject application, "on"
    End If
    Dim i
    Set xclapp = CreateObject("Excel.Application")
    Set xclapp = CreateObject("Excel.Application")
    Set xclwbk = xclapp.Workbooks.Open("c:\tmp\prices.xlsx")
    set xclsht = xclwbk.Sheets("Sheet1")
    For i = 2 To 50
    Macro will run for 50 rows.
    but i am required based on A column.
    if a colum have have only 10 the macro will be run only for 10.
    Please help.
    how can i modify the code?
    thanks

    Hello sir,
    I am not clear.
    Can you Please explain.
    If Not IsObject(application) Then
       Set SapGuiAuto  = GetObject("SAPGUI")
       Set application = SapGuiAuto.GetScriptingEngine
    End If
    If Not IsObject(connection) Then
       Set connection = application.Children(0)
    End If
    If Not IsObject(session) Then
       Set session    = connection.Children(0)
    End If
    If IsObject(WScript) Then
       WScript.ConnectObject session,     "on"
       WScript.ConnectObject application, "on"
    End If
    Set xclapp = CreateObject("Excel.Application")
    Set xclapp = CreateObject("Excel.Application")
    Set xclwbk = xclapp.Workbooks.Open("c:\tmp\prices.xlsx")
    set xclsht = xclwbk.Sheets("Sheet1")
    For i = 1
    While (not Range("A" & i).Value = "")
    session.findById("wnd[0]").maximize
    session.findById("wnd[0]/tbar[0]/okcd").text = "/nmen"
    session.findById("wnd[0]").sendVKey 0
    session.findById("wnd[0]/usr/subSUB0:SAPLMEGUI:0016/subSUB2:SAPLMEVIEWS:1100/subSUB2:SAPLMEVIEWS:1200/subSUB1:SAPLMEGUI:3212/cntlGRIDCONTROL/shellcont/shell").modifyCell 0,"BNFPO",xclsht.cells(i,1).Value
    session.findById("wnd[0]").sendVKey 0
    session.findById("wnd[0]/tbar[0]/btn[11]").press
    session.findById("wnd[1]/usr/btnSPOP-VAROPTION1").press
    i = i + 1
        Wend
    Can you Please
    Edited by: hpvinu on Mar 1, 2012 4:19 PM

  • Microsoft Excel VB Macro Help!

    Hi all,
    I am currently working on a basic Stock Control sheet where the current stock is on one sheet and then there is another sheet for re-ordering stock. What I need to happen is when I click a button at the end of the row it copies certain cells from this sheet
    over to the next available row on the other sheet whilst also taking the value down in cell M8 by 1 (I haven't added this bit in yet but need help in doing so please!)
    My Code is below for what I have but it keeps adding it into row 8 on the re-order sheet instead of adding it in the next available row if row 8 is already in use? Can someone help please?!?
    Sub NewOrderRow8()
    ' NewOrderRow8 Macro
    response = MsgBox("Are You Sure You Want To Add This To The Order List?", vbYesNo)
    If response = vbNo Then
    ' MsgBox ("Macro Ending")
    Exit Sub
    End If
    Application.ScreenUpdating = False
    Dim copySheet As Worksheet
    Dim pasteSheet As Worksheet
    Set copySheet = Worksheets("Inventory Control")
    Set pasteSheet = Worksheets("Re-Order Sheet")
    copySheet.Range("B8:D8,G8:I8").Copy
    pasteSheet.Cells(Rows.Count, 1).End(xlUp).Offset(1, 2).PasteSpecial xlPasteValues
    Application.CutCopyMode = False
    Application.ScreenUpdating = True
    End Sub
    Many Thanks!
    Daniel

    Re: paste into wrong row
    You are pasting into column(3) but checking for the last row in column(1).
    Change Offset(1,  2) to...
    pasteSheet.Cells(Rows.Count, 1).End(xlUp).Offset(1, 0).PasteSpecial xlPasteValues
    Jim Cone
    Portland, Oregon USA
    free & commercial excel programs
    https://jumpshare.com/b/O5FC6LaBQ6U3UPXjOmX2

  • Macros help?

    Hi experts,
                    My requirement is to design a macros for a planning book where apart from other fields i need to compute open demand and shipment plan.My shipment plan formula invloves open demand of previous day and open demand formula needs the shipment plan for the previous day.So i cannot calculate any one of this key figure before the other. But if i calculate all the key figures for one column first and then the next column and so on , then i suppose it will work fine .But i am not able to compute it one column after the other.I am able to do it only one keyfigure at a time across all columns .Can any of you kindly help to compute the key figures column wise
    Kindly help
    regards
    Ashwin

    If you want to avoid the BADIs path, I would recommend to execute the Macro multiple times. ( as many times as number of time buckets) This sounds very performance intensive, however if your calculations are simple, it should be ok.
    The way to do it multiple times will be to use layers of collective macro.

  • How does Macros help which in Queries ?

    Guys ,
    I wanted to know in detail about the macros.How does they help which are available in Excel sheet of the Bex analyzer.

    A good starting place would be the SAP Help pages on the topic at:
    <a href="http://help.sap.com/saphelp_nw04/helpdata/en/f1/0a55f9e09411d2acb90000e829fbfe/content.htm">http://help.sap.com/saphelp_nw04/helpdata/en/f1/0a55f9e09411d2acb90000e829fbfe/content.htm</a>
    Hope this helps...
    Bob

  • Macro help on selectin crieteria with time dimension to the user

    Hi Experts,
    I have some Macro requirement in my input schedule.
    We are preparing Head Count Planning report and the time dimension is selected for next five years and category is Budget.
    Now user wants to select only on year wise and then the report needs to be refreshed with the selected year (Example selected budget year is 2015).
    I have heard that it can be achieved through Macro. Can some one please provide a piece of Macro sample so that I can make the changes according to my requirement.
    Please see the below report format (Time Dimension details).

    Hi Satish,
    What macro are you talking about?
    If it's symmetric report then you use context to select YYYY.TOTAL and expand to base members.
    If it's asymmetric report then use: Static report in BPC NW 10
    "Now user wants to select only on year wise and then the report needs to be refreshed with the selected year (Example selected budget year is 2015)."
    If you want to have report for 5 years and the user select first year with context - then Static report in BPC NW 10
    You have to generate TIME members by Excel formula:
    Example:
    in A10 you have formula =EPMContextMember("ConnName";"TIME"), resulting in 2015.01
    Then in column axis you can use LEFT($A$10,4)&".02", LEFT($A$10,4)&".03" etc. for the first year
    LEFT($A$10,4)+1&".02",... for the second year
    Vadim

  • Excel Macro help

    Dear Experts,
    I need to filter the following shown in the BEx report:
    _______From_______To
    A_B_C_01.01.2010__01.01.2011
    A_B_C_01.02.2011__01.03.2011
    A_B_C_01.04.2011__31.12.2011
    To filter to or hide the rest:
    A_B_C_01.04.2011__31.12.2011  (latest  'To' Date)
    Could you kindly provide an Excel macro to do the above such that for each A-B-C combination the one with the furthest  'To' date?
    Thanks.
    Best regards
    Bass

    bump *

  • Macro help needed Urgently

    Hi All
    If I want to hard code the processing dates what is the setting required . What I mean by hard coding is that when the month rolls the the months for which the macro is procssed should not change.
    For exmaple
    If I have defined a macro like
    Step ( From 07/009-09/2009)
    Cell:  Seasonal net DP(07/2009) =
    sum (
    cell:net dp(07/2009)
    cell:net dp(08/2009)
    cell:net dp(09/2009)
    So when the month rolls (that is the next month comes ove)r i want this macro to take the value of net dp of 07/2009, 08/2009 and 09/2009 and assign it to cell : seasonal dp (07/2009) only as is presently defined
    Please let me know how this can be done.
    I beileve that if at the step level I uncheck the Autimatic adjutment from and to column this can be done. I am not sure though..

    As seen below from the illustartion I gave the date dependent option at the step level
    and I gave the start date as 07/01/2009 and end date as 09/30/2009
    Now after the month roll I noticed that though the step level definition remained the same and the month at the step definition  didn't roll but the cells which were defined under the steps rolled .
    What I mean is that at the start  my macro looked like this as shown below
    Step ( From 07/009-09/2009)
    Cell: Seasonal net DP(07/2009) =
    sum (
    cell:net dp(07/2009)
    cell:net dp(08/2009)
    cell:net dp(09/2009)
    and after the month rolled the macro looked like this
    Step ( From 07/009-09/2009)
    Cell: Seasonal net DP(08/2009) =
    sum (
    cell:net dp(08/2009)
    cell:net dp(09/2009)
    cell:net dp(10/2009)
    I don't want the cell value to roll . Please let me know the setting
    bulbuljb

  • Encrypt with password using an EXCEL macro

    I created a PDF using a macro in EXCEL 2010.  Can I encrypt the PDF using the macro?  I want to encrypt all document contents and restriction permissions to high resolution printing.

    Hi Ralph,
    Please post the query in Microsoft forums.
    You might want to refer to the below threads :
    https://forum.openoffice.org/en/forum/viewtopic.php?f=30&t=54705
    http://www.excelguru.ca/forums/showthread.php?1412-Need-Macro-Help-to-send-a-worksheet-as- PDF
    Regards,
    Rave

  • Saving macro results between steps

    All,
    We have a requirement where we need to save the results from Step 1 of the macro into the livecache before executing the next step - standard macros do not save the results until the Save icon is clicked on. Any ideas on how to do this? Essentially, I am looking to replicate the Save icon except that it is to be triggered from within the macro.
    Thanks
    AR

    I dont think it is possible to do that in foreground mode. Even if you use collective macro there is nothing you can do to save intermediate steps. That is a basic design issue about macros. I think this fact is well documented as well in Macro help.
    If you are doing this in batch however, you should use multiple steps in the activity or multiple activities itself to make sure intermediate steps are committed to the DB.

  • Help needed in Macro

    Hello Experts,
    I am creating a macro, where the requirement is; user would select few columns of a KF & hit on a macro.
    The values in the KF should get multiplied by 2.
    Any clue how should I add ( *2) functionality in operation / function ?. Any other suggestion is welcomed.
    Please help
    Regards
    Rahul Chitte

    Hi Rahul,
    You can set the macro to run for few period.
    1)  In the step of the macro, select the period you want to run
    2) Within the step, Results row (Key figure row 'XXX") = Key figure row 'XXX" * 2 (remember to maintain a space between * and 2)
    3) Check the macro for any error, which would help you for any inconsistencies
    4) activate the macro to test your requirement.
    hope this would solve your requirment.
    Regards,
    Nawanit

  • Urgent help needed on Macros

    Hi APO Gurus...
    I want to know how to use Drill_Up and Drill_ Down macros in batch jobs. they work beautifully in interactive mode, but when processed in batch jobs they drill up only for the particular CVC's at the aggregated level specified in the job. We are  selecting all the characteristics in the aggregation level while creating the job. Then we want to drill up on particular characteristic. We are using a collective macro with first macto for drill up and second macro for calculations at the aggregated level. It works fine in interactive mode but drill_up doesnt seem to work in batch jobs.
    Help needed

    Hi,
    You should not be using DRILL_UP and DRILL_DOWN functions in background jobs. Whatever processing you need to do after DRILL_UP should be a separate macro and that should be executed in background at the desired aggregation level (set for the job).
    There is no point in using a collective macro with a DRILL_DOWN, processing and DRILL_UP steps in background job.
    Thanks,
    Somnath

Maybe you are looking for

  • New Bank A/C Creation Error

    Hi everyone, While creating a new bank Account i am getting following error.... "Unable to verify the value entered into the OrgName field. Please select the List of Values icon for this field to select a valid value." this error actually arrises whe

  • Password protecting certain documents

    I have several documents I would like to password protect individually. Is this possible and if so, how?

  • Function in free Adobe Reader apps for iPad (highlight pen)

    I wonder for the free Adobe Reader apps that I can found in Apps Store. Do its function are the same as those normal Adobe Reader, which is designed for using on PC / laptop? Any function in the free Adobe Reader apps will be missing due to the desig

  • Loading Hierarchy (ex : 0COSTCENTER) from different R/3 system to SAP BW

    Hello, I would like load 2 hierarchies (EX : 0COSTCENTER) from 2  SAP R/3 systems. The problem is I have the same 0NODE_NAME in the both system. I add 0SOURSYSTEM as compouned key in 0COSTCENTER. But I doesn't work. I don't see the 0NODE_NAME compoun

  • Camera Raw 6.5 update

    Tried to update PS CS5 camera raw 6.5 Update -installation failed (mac)