created udf in ledger master now wanna fetch details from a group of ledger to it

Discussion in 'Free Source Codes' started by ankitinfo, Aug 18, 2023.

    
  1. ankitinfo

    ankitinfo Member


    i have created 2 udf fields in ledger creation master and wanna fetch group of ledger to save data in that field
     


  2. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    The "Group" of Ledger is already there in Ledger Master .... so what exactly do you need a new Field/UDF for ??
     


  3. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    Make a Collection / Table of Ledgers --- Filter it -- if belongs to Group named "broker"

    Add this LINE in your field --- Table : YourTableName
     


  4. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    I take it to understand that you are new to coding and making good efforts to learn, but simply copying code will not work always -- even if you do copy -- then try to understand the coding logic. It will help you learn faster and better.

    [Field:Broker]
    Use:name field
    Set As : $$Value
    Table : brokerlist
    Show Table : always
    set always : yes
    Storage:Broker
    Width:30

    [Collection : brokerlist]
    type : ledger
    filter : onlybroker

    [system : formula]
    onlybroker : $Parent:Ledger:$Name = "Broker"
     
    ankitinfo likes this.


  5. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    You cannot FETCH a FIELD in your collection only UDFs can be fetched.

    Study the Field -- [Field: EI ValueSubTotal] in Tally Developer ►► see how the value has been derived.

    Compute in the same manner in your collection.
     


  6. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    If you are referencing a field -- it has to be in the same report -- and secondly you have to use # not $.

    Most importantly, you have not read the last line of my post -- I asked you to COMPUTE in your report Collection.

    Now I do not know your Report and full code and I do not know how and where you are trying to get the Value -- so you need to workout the same on your own. If you are outstation and still working you can download Developer -- it is not a big installation.

    Another hint : Use Function $$CollAmtTotal to compute the value.
     


  7. Hems

    Hems Member




    In collection
    Fetch : amount

    For total bill amount

    Set as : $Amount


    Before tax amount
    Set as :$$CollAmtTotal:allinventoryEntries:$Amount
     


  8. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    E-Way bill will be associated with a SALES VOUCHER not the Ledger Account.

    make a Collection of Sales Vouchers -- compute/extract the E-way bill information and call for it in your Main Report collection.
     
    ankitinfo likes this.


Share This Page