MARK

navuser1navuser1 Member Posts: 1,329
Hi All,

Plz See the code in Screen shot...


Line 1 marks five different Items, but Line 2 opens the Item List form only with the One Item. This is the issue ???
Now or Never

Comments

  • navuser1navuser1 Member Posts: 1,329
    edited 2009-05-12
    ](*,)
    Now or Never
  • navuser1navuser1 Member Posts: 1,329
    :roll:
    Now or Never
  • matteo_montanarimatteo_montanari Member Posts: 189
    edited 2009-05-12
    navuser1 wrote:
    Hi All,

    Plz See the code in Screen shot...


    Line 1 marks five different Items, but Line 2 opens the Item List form only with the One Item. This is the issue ???


    Hi

    Before the markedonly, remove the "item No." filter applyed on previus loop...

    Something like:

    ...
    RecItem.SETRANGE("No.");
    RecItem.MARKEDONLY(TRUE);
    ...

    Bye

    Matteo
    Reno Sistemi Navision Developer
  • MalajloMalajlo Member Posts: 294
    In first loop you've marked several records and then you have them. Where is the problem?
    I assume you have to add something like "if stdurchline.remaining qty <> 0 then do... mark(true)"...
  • David_SingletonDavid_Singleton Member Posts: 5,479
    You waited a whole 60 seconds to bump the topic. Were you expecting a faster response time? [-(
    David Singleton
  • DenSterDenSter Member Posts: 8,304
    Line 1 does not mark 5 records, you are only finding 1 record, so I would expect the list form to only show one record. You will have to loop through all records in the filter and mark all of them.
  • DenSterDenSter Member Posts: 8,304
    Wait, hold on, eto is on the right track. You should do a GET on the Item table, because you know the item number. Then right before you do MARKEDONLY, you should do a RESET first. The issue is that you have a filter on the item number, so by the time that you are showing the form, you have a filter on the item number, and MARKEDONLY=TRUE. Do a RESET to remove all filters, then do MARKEDONLY, and then you should see all marked items in your list.
  • MBergerMBerger Member Posts: 413
    erm... DON'T do a RESET... RESET clears all marks !
  • DenSterDenSter Member Posts: 8,304
    Oh it does? Oops, my bad :oops: I never use MARK myself, I would do this with a temporary record variable.

    Then you need to clear the filter on the "No." field before the MARKEDONLY.
  • navuser1navuser1 Member Posts: 1,329
    Thanks to all....
    If I use the code below.......
    IF ItemRec.GET( StdPurchLine."No.") THEN.... instead of the SETRANGE.


    This will solve my issue.........

    But It would be more safer to use the Temporary Table concept instead of the MARK Function (As Daniel mentioned ) :mrgreen:
    Now or Never
Sign In or Register to comment.