How to Delete a full Line from Showing a Report..... Like Reminder

Discussion in 'Free Source Codes' started by Murari Bajaj, Oct 22, 2020.

    
  1. Murari Bajaj

    Murari Bajaj Member


    Dear Experts

    Please let me know can we delete a line from the Reminder given in Image...
    instead of deleting Work... Date and all fields individually ... can we delete the full line
    like Alt + D type or something else... Report Line Delete.jpg
     


  2. Himanshu-2002

    Himanshu-2002 Active Member


    Create a key
    Example:
    [Key: MyDeleteKey]
    Key: Alt + D
    Action: Call: Func

    Define a function which will delete that line from collection

    1. Create a collection of current line
    2. Walk through the collection and delete target

    *I am not very sure about this solution But The solution will be very similar to this
     
    Murari Bajaj likes this.


  3. Murari Bajaj

    Murari Bajaj Member


    Thanks Himanshu for prompt suggestion.
    I think this may may work.
    But actually i do not know how to delete a single line from a collection....
    will it be with some filter or what.... please suggest with some small Exemple for retrieving the single line
    from a collection....
    It will be helpful
    Thanks again.
     


  4. Murari Bajaj

    Murari Bajaj Member


    Or if there is a code .... if the cursor can recognize the current field selected and similirly the full line...
    like it happens in VBA.
     


  5. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    Or make a simple solution....

    Add a column at the end ........ for Yes or No

    Then in code.... use --- Remove If : #Field Contains "yes" .....
     


  6. Murari Bajaj

    Murari Bajaj Member


    Okay Amitji i will try this but can it not be deleted with Serial No in the form.
    Thanks
     


  7. Himanshu-2002

    Himanshu-2002 Active Member


    Use $$Line instead of $$LineNumber So, It will work
     


  8. Himanshu-2002

    Himanshu-2002 Active Member


    And to Fetch Data of current line you can make a collection like this

    [Collection: CurrentLineColl]
    Data Source: Report: Current Line
    Fetch: ;;; Method Names Which you want to fetch from current line
     


  9. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    You already have a column for STATUS ........ revise your code...Remove If : #StatusField contains "yes"

    When it can be done simply, why are your taking a complicated route ??
     


  10. Murari Bajaj

    Murari Bajaj Member


    I have already use $$Line...
     


  11. Himanshu-2002

    Himanshu-2002 Active Member


    Use the method which amit sir Told because My solution is a bit complicated and I am not very sure about it So, I will prefer you for easy one rather than unnecessary tough one
     


  12. Murari Bajaj

    Murari Bajaj Member


    I am giving here the full code please see if something can be done....
     

    Attached Files:



  13. Murari Bajaj

    Murari Bajaj Member


    and also please how to prevent it from loading in all companies. Allow only in which AddOn page allows it.
    I tried but Buttons do not hide by not allowing in AddOn list.
     


  14. Himanshu-2002

    Himanshu-2002 Active Member


    Did you made this code? If Yes then I am sure you can solve it easily and I can solve this issue but This is not going to help you in any way So, Try to solve it we will help you
     


  15. Murari Bajaj

    Murari Bajaj Member


    No this is not fully made by me.... I added Status Column to it some formtting and Sorting with Date.
    It will be helpful if the line is deleted by selecting etc.
     


  16. Murari Bajaj

    Murari Bajaj Member


    And yes filter also added by me. Still i am in learning phase.
     


  17. Sajith Sabu

    Sajith Sabu New Member


    Try This


    Code:
    [Button:  DeleteValue]
    
        Key         : Alt+D
        Action      : Multi Field Set : Field1, FIeld2 : 0
        Title       : $$LocaleString:"Delete Value"
        Inactive    : NOT $$InAlterMode
        Scope        : All
     


  18. Murari Bajaj

    Murari Bajaj Member


    Sorry Sabu ji it is not working. Thanks for the try.
     


  19. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    He has given a EXAMPLE..........you are supposed to replace the field name and Action name.
     


  20. Sajith Sabu

    Sajith Sabu New Member


    No it is working... Please Check

    Action : Multi Field Set : Field1, FIeld2 : 0

    (Field1, Field2) -> Replace your field name


    I Am already use this code

    [Button : BlankDueAmount]

    Key : Alt+Z
    Action : Multi Field Set : AutoDueLedger, AutoDueEntryAmt : 0
    Title : $$LocaleString:"Delete Details"
    Inactive : NOT $$InAlterMode
    Scope : All


    upload_2020-10-24_9-21-8.png
     
    Last edited: Oct 24, 2020


  21. Murari Bajaj

    Murari Bajaj Member


    Yes Sabuji i have changed the field names but still its not working.... My codes are in the thread itself please try.
    i think there is some minor mistake is happening.
    Thanks
     


  22. Murari Bajaj

    Murari Bajaj Member


    Dear Sabu
    It is Solved now....
    Actually i was using Field's Storage names but it required the Field own names.
    secondly one more important thing i used
    Scope : Current Line
    otherwise it was deleteing all the records for that field.
    Thank you so much.
     
    Sajith Sabu likes this.


Share This Page