neednegative stock control for tally prime

Discussion in 'Free Source Codes' started by Tarun Waghwani, Dec 9, 2020.

    
  1. Tarun Waghwani

    Tarun Waghwani New Member


    need negative stock control for tally prime if any body have plz send..
     
    Last edited: Dec 9, 2020


  2. kishan369

    kishan369 New Member


    [#Field : VCH Batch NrmlAQty]

    Control : Negative Stock : ##VCFGNegativeStock AND ($$InCreateMode) AND $$IsNegative:mad:@FinalStockTotal



    [#Field : VCH Batch NrmlBQty]

    Control : Negative Stock : ##VCFGNegativeStock AND ($$InCreateMode) AND $$IsNegative:mad:@FinalStockTotal


    [#Field : VCH Batch jrnlBQty]

    Control : Negative Stock : ##VCFGNegativeStock AND ($$InCreateMode) AND $$IsNegative:mad:@FinalStockTotal

    [#Field : VCH NrmlActualQty]

    Control : Negative Stock : ##VCFGNegativeStock AND ($$InCreateMode) AND $$IsNegative:mad:@FinalStockTotal
     


  3. Tarun Waghwani

    Tarun Waghwani New Member


    [#Line: EI InvInfo]

    Option : TSPL FFE Neg Stk EI InvInfo : @@TSPLFFEIsNSC AND @@IsOutwardType

    [!Line: TSPL FFE Neg Stk EI InvInfo]

    Add : Right Fields : TSPL FFE Final Qty
    Local : Field : VCHActualQty : Control : TSPL FFE NegativeStock : $$IsNegative:mad:@TSPLFFEClosQty AND $ActualQty != $BilledQty
    Local : Field : VCHBilledQty : Control : TSPL FFE NegativeStock : $$IsNegative:mad:@TSPLFFEClosQty AND $ActualQty = $BilledQty
    On : Focus : Yes : CALL : TSPL FFE Set List Variables : $$Line : "Item"

    ;; Altering Batch Line

    [#Line: STKVCH Batch2]

    Option : TSPL FFE Neg Stk STKVCH Batch2 : @@TSPLFFEIsNSC AND @@IsOutwardType

    [!Line: TSPL FFE Neg Stk STKVCH Batch2]

    Add : Right Fields : TSPL FFE Final Qty, TSPL FFE Orig Qty
    Local : Field : VCHBATCH ActualQty : Control : TSPL FFE NegativeStock : $$IsNegative:mad:@TSPLFFEClosQty AND $ActualQty != $BilledQty
    Local : Field : VCHBATCH BilledQty : Control : TSPL FFE NegativeStock : $$IsNegative:mad:@TSPLFFEClosQty AND $ActualQty = $BilledQty
    On : Focus : Yes : CALL : TSPL FFE Set List Variables : $$Line : "Batch"

    [Field: TSPL FFE Final Qty]

    Use : Qty Primary Field
    Set As : @@TSPLFFEClosQty
    Invisible : Yes
    Set Always : Yes
    Skip : Yes

    [Field: TSPL FFE Orig Qty]

    Use : Qty Primary Field
    Storage : TSPL FFE Orig Qty
    Set As : if $$IsEmpty:$$Value then $ActualQty else $$Value
    Invisible : Yes

    [System: UDF]

    TSPL FFE Orig Qty : Quantity : 1000

    [Function: TSPL FFE Set List Variables]

    Parameter : pLine : Number
    Parameter : pItemBatch: String

    Variable : LineKey : String
    Variable : LineIndex : Number

    00 : IF : ##pItemBatch = "Batch"
    10 : SET : LineKey : $StockItemName + #VCHBATCHName + #VCHBATCHGodown
    20 : IF : NOT $$ListFind:TSPLFFEBatchVar:##LineKey
    30 : LIST ADD: TSPL FFE BatchVar : ##LineKey
    40 : ENDIF
    50 : SET : LineIndex : $$ListIndex:TSPLFFEBatchVar:##LineKey
    60 : SET : TSPL FFE BatchVar[##LineIndex].TSPL FFE OrigBatch : #VCHBATCHName
    70 : SET : TSPL FFE BatchVar[##LineIndex].TSPL FFE OrigGodown : #VCHBATCHGodown
    80 : SET : TSPL FFE BatchVar[##LineIndex].TSPL FFE OrigQty : if $$IsEmpty:##TSPLFFEBatchVar[##LineIndex].TSPLFFEOrigQty then #TSPLFFEOrigQty else if ##pLine = ##LineIndex then ##TSPLFFEBatchVar[##LineIndex].TSPLFFEOrigQty else ##TSPLFFEBatchVar[##LineIndex].TSPLFFEOrigQty + #TSPLFFEOrigQty
    90 : ELSE :

    100 : SET : LineKey : #VCHStockItem
    110 : IF : NOT $$ListFind:TSPLFFEItemVar:##LineKey
    120 : LIST ADD: TSPL FFE ItemVar : ##LineKey
    130 : ENDIF
    140 : SET : LineIndex : $$ListIndex:TSPLFFEItemVar:##LineKey
    150 : SET : TSPL FFE ItemVar[##LineIndex].TSPL FFE OrigItem : #VCHStockItem
    160 : SET : TSPL FFE ItemVar[##LineIndex].TSPL FFE OrigQty : if $$IsEmpty:##TSPLFFEItemVar[##LineIndex].TSPLFFEOrigQty then #VCHActualQty else if ##pLine = ##LineIndex then ##TSPLFFEItemVar[##LineIndex].TSPLFFEOrigQty else ##TSPLFFEItemVar[##LineIndex].TSPLFFEOrigQty + #VCHActualQty
    170 : ENDIF


    [System: Formula]

    TSPL FFE IsNSC : $TSPLFFEControlNegStk:Company:##SVCurrentCompany

    TSPL FFE ClosQty : if $$InAlterMode then @@FinalStockTotal + @@TSPLFFELVQtyBatchItem else @@FinalStockTotal
    TSPL FFE LV Qty BatchItem : If @@HasBatchWise OR $$IsMultiGodownOn then ##TSPLFFEBatchVar[$$ListIndex:TSPLFFEBatchVar:mad:@TSPLFFEBatGdn].TSPLFFEOrigQty else +
    ##TSPLFFEItemVar[$$ListIndex:TSPLFFEItemVar:$StockItemName].TSPLFFEOrigQty

    TSPL FFE BatGdn : $StockItemName + #VCHBATCHName + #VCHBATCHGodown

    TSPL FFE NegativeStock : $$SPrintf:mad:@NegativeStockFormat:mad:@TSPLFFENegativeStkFormula
    TSPL FFE NegativeStkFormula : $$String:mad:@TSPLFFESignedStockTot:Signed
    TSPL FFE SignedStockTot : @@TSPLFFEClosQty


    [#Part: VCFG Inventory]

    Local : Line : VCFG NegativeStock : Invisible : Yes


    [Variable: TSPL FFE ItemVar]

    Variable : TSPL FFE OrigItem : String
    Variable : TSPL FFE OrigQty : Quantity

    [Variable: TSPL FFE BatchVar]

    Variable : TSPL FFE OrigBatch : String
    Variable : TSPL FFE OrigGodown : String
    Variable : TSPL FFE OrigQty : Quantity

    [System: Variable]

    List Variable : TSPL FFE BatchVar, TSPL FFE ItemVar


    [#Report: Voucher]

    Variable : VarDummy : Logical
    Set : VarDummy : $$TSPLFFEDeleteLV

    [Function: TSPLFFEDeleteLV] ;; Function deleting System List Variable values

    00 : LIST DELETE : TSPL FFE BatchVar
    05 : LIST DELETE : TSPL FFE ItemVar
    10 : RETURN : True

    [#Part: CMP InvFeat Right]

    Add : Lines : After : CMP UsePriceLevels : TSPL FFE Control Neg Stk

    [Line: TSPL FFE Control Neg Stk]

    Fields : Medium Prompt, TSPL FFE Control Neg Stk
    Local : Field : Medium Prompt : Set as : $$LocaleString:"Control Negative Stock ?"
    Invisible : NOT $IsInventoryOn
    Space Top : 0.4

    [Field: TSPL FFE Control Neg Stk]

    Use : Logical Field
    Set as : If NOT $IsInvoicingOn then "No" else $$Value
    Storage : TSPL FFE ControlNegStk
    Skip : If $$IsRemoteCompany Then Yes Else NOT $IsInvoicingOn
    Set Always : Yes

    [System: UDF]

    TSPL FFE Control Neg Stk : Logical : 1100

    ;; End-of-File





    Need Help in Above TDL Not Working In Tally Prime
     


  4. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    What seems to be the problem?? check out where the problem is ... Press --- Ctrl + Alt + T ..... and it will give you the error.

    Find the new PART name in Prime and replace it.
     


  5. NiravMerchant

    NiravMerchant Active Member


    [#Part: CMP InvFeat Right]
    this part is not in Tally Prime
     


  6. piyush R

    piyush R New Member


    In Prime developer find part [#Part: Company F11 Inv Features] i hope it will helpfull
     


Share This Page