Validation: usage of "Complete Document" event

Hi All.
I'm trying to implement a Validation which checks several conditions in a Document to know if it is valid or not.
Since these conditions are spread between the Document's lines, I choose the "Complete Document" event and expected to get a table of all lines, but it is not the case.
I debugged the code and found that the SAP code that calls my code has a parameter called BOOL_DATA which is a table that holds the BKPF structure (of course) and also all the Document lines (stored as a table in its BSEG field).
However, this BOOL_DATA is not used at all when my Validation is called.
2 questions:
1.
How can I use this BOOL_DATA table so I can see all the Document's lines?
2.
If this param cannot be used, what the difference between the "Line Item" event and the "Complete Document" event in terms of what I can see and use?
Regards.
Ayal Telem.

Hi Ayal Telem,
Dear Md Faheem.
I was not familiar with this subject.
Thank you very much for the info.
I started to read the documentation you referred me to and it looks interesting.
I will update after implementation.
Regards.
Ayal Telem.
That's good. Ask me anything if you struck up somewhere.
Thanks & Regards,
Faheem.

Similar Messages

  • FI Substitution rule on completed document

    Hi Everyone,
    We're trying to create a substitution rule to change the payment terms on our invoices (fields BSEG-ZTERM and BSEG-ZBD1T).  We're having trouble with our prerequisite:  If any of the expense distributions are being charged against a federal grant (BSEG-GRANT_NBR) then call the substitution rule.   We want our exit to loop through all distribution lines and if it finds any being charged to a grant it should set the condition to true and substitute...if it doesn't find any it should be set to false. 
    We've done all of the necessary steps:
    -Activated the fields on GB01
    -Defined the substitution rules on OBBH
    -Build and compiled the user exit.
    Problem we're having is that when there are multiple lines it only seems to be reading the last line item to make the determination.
    Example 1:
    Line 1 Grant
    Line 2 No Grant
    Result is that payment terms are not substituted.  It should be substituted because line 1 hit a grant.
    Example 2:
    Line 1 No Grant
    Line 2 Grant
    Result is that payment terms are substituted correctly. 
    My ABAPer says that the problem seems to be that on the completed document he can only see the last line (not all the lines)....does anyone know a way to loop through all the records on a completed document?  It seems that substitution gets called before records get inserted into the database so we're not sure how to make our pre-requisite work.
    thanks for your help

    Hi,
    here is the solution.
    Create your user exit.
    FORM u280 USING bool_data TYPE gb002_015.
    FIELD-SYMBOLS: <ls_bseg> LIKE LINE OF bool_data-bseg,
    LOOP AT bool_data-bseg ASSIGNING <ls_bseg>.
    * Here is your logic needed
    ENDLOOP.
    Create a substitution for the complete document in GGB1 and choose no field but "Only exit'.

  • PDS Appraisal Completed - Document not visible to manager

    Dear ,
    We are going live with Objective settings and performance appraisal. The functionality working well except an issue. The completed appraisal of subordinate is not visible to manager where as the same is visible to employee.
    Any idea why manager nnot able to see completed document after employee agreed on the PDS?
    Thanks in advance

    Hi,
    Thanks for your reply.
    1. "Please check role tab under category and template which you have been defined"
             In the category and Manager we selected
                    Self
                    Manager
                    Higher manager
    2. under this how many level of employee you have selected in which way like appraiser, and appriasee, like manager, co worker .
          (Employee>Manager>Higer Manager-->HOD )
          Employee
          Immediate Manager (line Manager)
          Higher Manager ( Manager of Line Manager )
          HOD (Cost centre Owner)
    3..more over you check manager position coming under which position....
         I am not clear about the above , can you eloborate?

  • Document events for text replacement

    Hello!
    This is a question about Document events in JTextComponent.
    Two document events in a row are fired when the user performs a text replacement (some text is selected and the user inserts or pastes new text): first, DocumentListener.removeUpdate is called for the selected text being removed; second, insertUpdate for the text being inserted or pasted.
    The question is: how can I be aware that both events are related and exist in response for the same and unique action?
    More specifically, I need to know that the remove event is part of a two-step edition in order to bypass execution flow.
    I have some bizarre ideas in mind, like proxing the original ActionMap "paste" action (for pasting) and tracking the keyboard (for inserting), but I don't think this is a too elegant approach.
    Please let me know if you would find helpful some sample code.
    Thank you!

    That's from JTextComponent replaceSelection() method source
       public void replaceSelection(String content) {
            Document doc = getDocument();
            if (doc != null) {
                    if (doc instanceof AbstractDocument) {
                        ((AbstractDocument)doc).replace(p0, p1 - p0, content,null);
                    else {
                        if (p0 != p1) {
                            doc.remove(p0, p1 - p0);
                        if (content != null && content.length() > 0) {
                            doc.insertString(p0, content, null);
    ...As you can see it calls ((AbstractDocument)doc).replace() in the most cases all the default EditorKits uses AbstractDocument extensions.
    Then from AbstractDocument's replace
        public void replace(int offset, int length, String text,
                            AttributeSet attrs) throws BadLocationException {
            DocumentFilter filter = getDocumentFilter();
                if (filter != null) {
                    filter.replace(getFilterBypass(), offset, length, text,
                                   attrs);So I think you can set your own DocumentFilter and override the filter's replace. Set the flag replaceStarted=true and call super.replace(). In the DocumentListener just check the flag.

  • Combining "allowMultipleInstances" with "OS Open Document" event = Catastrophe!

    Hey folks,
    I'm combining two somewhat "off-book" LabVIEW features here. Hoping I can get some help from the experts!
    I have an application (named APT) which has been built into an executable. In the .ini file, "allowMultipleInstances=TRUE". So calling the application more than once results in multiple instances.
    I also have the "OS Open Document" event, which triggers when the user opens .csv files from Windows Explorer.
    "OS Open Document" has been workingly splendidly for a couple months. I was recently asked to add the multiple instances case by the enduser, which I did. Now with both features, I get the following behavior:
    1) If my application is NOT the default program, then performing an "Open With --> APT" causes the file to open in Excel (?). Then APT opens, but doesn't load the file data. It acts as though it's been called without loading any file information.
    2) If my application IS the default program, then endless instances of APT begin appearing. This forces a restart.
    Has anyone had any sort of experience with combining these two features? Any ideas on how to make them play nicely together? If not, I think I may have to break it to the enduser that he can only have one or the other.
    Thanks.
    http://linkd.in/mikele

    You must be using an older version of LabVIEW. That event isn't exposed in LabVIEW 2011, as far as I know. In fact, Ton submitted an idea to provide a native way to handle this.
    Given that the event you are using isn't documented, it's anybody's guess as to what the problem is. At the very least we would need to see some code to have a chance at guessing what the problem might be. It could be something as simple as a race condition.

  • Add eventlistener to catch after save document event?

    How can I catch a after save document event?
    Best regards
    / Pontus

    http://127.0.0.1:63632/help/index.jsp?topic=%2Fcom.adobe.cside.docs%2Freferences%2Fcshalib %2Fcom%2Fadobe%2Fcshostadapter%2FIDScriptingEventAdapter.html
    Harbs

  • JTextField & Document Event

    Hi I need to create a GUI like a calculator with number buttons. When I press 2 if this is the first character on the text field, I should set tp "B " [B and space]. I saw many examples of DocumentFilter and Document Event using to modify the data or generate events when pressing the keys. Then I need to add special characters after few more numbers are eneterd, eg for an input is "B 34.5567" using only keys 0-9.
    Another example was to use JFormattedTextField, I posted another question on the this and got some help to use DocumentFileter.
    I am facing a problem here on how to bind the keys from the GUI to these document events. When I press the keys, I can see events are fired, but cant use it to modify the JFormattedTextField. How should I do this? I am new to JAVA Swing. I am using the examples from the net to get this done.
    Thanks for help in any advance.

    user4071312 wrote:
    Another example was to use JFormattedTextField, I posted another question on the this and got some help to use DocumentFileter.
    what did you try so far? What happened when you used the suggestions in the other thread? Show us that you are trying, that infamous small runnable ... <g>
    BTW, personally, I think it rather impolite to ask a question, get some suggestions and then simply start over again in a new thread.
    I am facing a problem here on how to bind the keys from the GUI to these document events. please get your technical vocabulary right: in the context of Swing "bind keys" is a standing term. It's unrelated to document events.
    When I press the keys, I can see events are fired, but cant use it to modify the JFormattedTextField. assuming with "events" you mean the documentEvents in a DocumentListener: you don't modify the view, you modify the model (and preferably in a DocumentFilter, as you were already advised)
    How should I do this? I am new to JAVA Swing. Boils down to a very general question: How to learn :-) First you have to learn the basics. Start simple, read tutorials, read code, try to modify what you see, experience how it works (and fails <g>)
    I am using the examples from the net to get this done. not enough - you have to understand them. Now go ahead, choose a simple starter (like the one in snoracles online tutorial) and tweak until it works like you want
    Cheers
    Jeanette

  • Is the Jdev 10g complete document available ?

    As http://otn.oracle.com/documentation/9i_jdev.html, we only found few released notes document for 10g, Is whether planning to released complete document like Version 9.0.2 ? If yes, what is released date ?

    All the documentation is online in the tool.
    An HTML version will be out later on OTN.

  • Complete iPhoto event of daughter's prom gone.  Happened during iPhone 3 synch to mac air. No mojo, no weird key strokes, just another ordinary sync.  Event gone.  Apple no resolution.

    Complete iPhoto event of daughter's prom gone.  Happened during iPhone 3 synch to mac air. No mojo, no weird key strokes, just another ordinary sync.  Event gone.  Apple no resolution.

    With the amount of information you've provided it's impossible to offer a potential solution.  We can't see your computer so we need to know the details of your problem and setup, i.e.:
    what version of iPhoto are you using?
    what system version are you running?
    were the prom pictures on the iPhone 3 to begin with?
    what fixes have you tried?
    where is your library located?
    did you apply any updates or upgrades just prior to the problem occurring?
    are you running a "managed" or "referenced" library?
    what type of Mac?
    how much free space on your boot drive?
    OT

  • Would apple Support send me an email saying: "   We need to ask you to complete a short and brief step to securing and validating your account information.   Click here to complete validation   Failure to complete our validation process will result in a s

    We need to ask you to complete a short and brief step to securing and validating your account information.
    Click here to complete validation
    Failure to complete our validation process will result in a suspension of your Apple ID.

    You are welcome. The emails are difficult to block effectively, because the spammer/phishers continually fake their sending email address. You can, however forward the email to Apple.
    [email protected]

  • Verify bios integrity warning validation cannot be completed

    h61m-e33(b3)
    Hi I am attempting to update the bios on the above motherboard with file 7680vC3, just after starting the update in DOS it says it is verifying bios integrity and then i get a *******WARNING******** validation cannot be completed do you wish to continue y/n (not recommended) what do I do ?
    Thanks

    Oki, use this method with this archive file: https://forum-en.msi.com/index.php?topic=165930.msg1215345#msg1215345
    and try again

  • How to under complete document to configure prerequisite using fields both

    Hi,
       When I configure prerequisite under complete document for one substitution but fialed withe syntax error when I tried use the following prerequisite:
    BKPF-BUKRS = 'XXXX' AND
    BSEG-HKONT IN SET1
      But I input this prerequisite under line item it is ok . I am wondering if there is no permit for BSEG table field under prerequisite under complete document. Pls give me some advice on how to under complete document to configure prerequisite using fields both in BKPF and BSEG. Thanks.

    Hi Mohan,
       I did active it at call point3(complete document) but my question is when I configure prerequest I am confused that only BKPF data fields can be used in prerequest. Why field in BSEG can not be used in prerequisite?  Once I input BSEG field in prerequisite there will be syntax error message shown up.

  • Validation complete document level

    Dear All,
    I want to create one validation to restrict user at document type level. if document type DZ system should not allow entires like gl to gl postings.
    Regards,
    Sankar

    I think your requirement can be met through the configuration of Document Splitting through the indicator, "Only Once".  Below are the details of this indicator.
    Item type permitted only once
    If this parameter is selected, the corresponding item category may only be used once in the business transaction concerned. A document of this business transacation cannot be posted if the item category exists more than once.
    You may find this indicator in table V_T8G28 or menu path, "Define Business Transaction Variant" in configuration of Document Splitting.  Define a new variant or change the existing one attached with the Document Type DZ.
    Regards,

  • Change Validation to complete document level

    SAP experts,
    In tcode F-65 the business is using account assignment model to post recurring entries by filling in the template. Here it has a validation "Amount is Zero - line item will be ignored" at the Line item level. Business wants this validation to be changed from Line item level to the whole document level (at the time of save).
    The message no. is -- FX090
    "Amount is Zero - line item will be ignored"
    How can I change this validation settings?... please help asap.
    Thanks in advance.

    Dear Sameer,
    You would need to implement it at header level.
    For example in IMG under
    Financial Accounting -> Accounts Receivables and Accounts Payable -> Business Transactions -> Posting with alternative Reconciliation accounts -> Carry out and check document settings -> Validation in Accounting Documents.
    You can see some of the validations are implemented at item level and some at header level.
    Regards,
    Naveen.

  • FI Validations in GGB0 at complete document level

    Hi
    I have a requirement where i need to do a validation in FV60/65. Earlier, for a similar requirement for validation at the header level, i have used GGB0 and wrote custom code in the available userexit ( i had made a copy of RGGBR000 and implemented custom code in the copy) and replaced the standard program RGGBR000 in tcode GCX2)
    Now, when im trying to implement a similar solution at the line item the userexits in GGB0 are not being accessed by the tcode FV60. Can someone explain where i could have gone wrong.
    Note: I have activated the validations in OB28.
    Thanks
    Nag

    Closed

Maybe you are looking for