Is there an incompatible VBA Macro here to the ones zoho can read? Thanks
Sub APSMRUN()
STOCHSW = Application.Range("WPSW") 'Value of stochastic switch
If STOCHSW = 1 THEN Select JUMP1
Range("NOW").Select
Selection.Copy
Range("START").Select
ActiveSheet.Paste
JUMP1:
Call ADELEFIN
Calculate
Range("WPST").Select
Selection.Copy
Range("WPST1").Select
ActiveSheet.Paste
Dim NCYCLES As Integer
Dim TMAX As Integer
Dim NCROPS As Integer
Dim NLIVST As Integer
Dim GMA As Integer
NCYCLES = Application.Range("NCYC") '20-number of cycles/periods in the simulation
TMAX = Application.Range("NITR") '50-maximum number of iterations per cycle
NCROPS = Application.Range("NC") '9- number of crops market modeled
NLIVST = Application.Range("NL") '6- number of livestock markets modeled
ZLIMIT = Application.Range("ZTL")
NCOMM = NCROPS + NLIVST
GMA = 0
For CYCINDX = 1 To NCYCLES 'This is really the period or year
Range("NPERIOD").Select
ActiveCell = CYCINDX
For ITER = 1 To TMAX
If ITER > 1 Then Select AAA:
Range("PVARDP1").Select
ActiveCell.Offset(1, 0).Range("A1:H49").Formula = 0
AAA:
Range("DPG").Select
ActiveCell.Offset(7, 2).Range("A1").Select
Range("DPRICES1").Select
ActiveCell.Offset(ITER, 0).Range("A1").Select
Let NZERO = 0
For COMMINDX = 1 To NCOMM
ActiveCell.Offset(0, 1).Range("A1").Select
If Abs(ActiveCell) <= ZLIMIT Then NZERO = NZERO + 1
Next
If NZERO = NCOMM Then Select RECITERNO
Next
MsgBox "No convergence after " & TMAX & " iterations"
RECITERNO:
Range("NITER").Select
ActiveCell = ITER
Range("AREA1").Select
ActiveCell.Offset(ITER, 0).Range("A1:I1").Copy
Range("AREAFIN1").Select
ActiveCell.Offset(CYCINDX - 1, 0).Range("A1").Select
ActiveSheet.Paste
Range("YIELD1").Select
ActiveCell.Offset(ITER, 0).Range("A1:I1").Copy
Range("YLDFIN1").Select
ActiveCell.Offset(CYCINDX - 1, 0).Range("A1").Select
ActiveSheet.Paste
Range("PRICE1").Select
ActiveCell.Offset(ITER, 0).Range("A1:I1").Copy
Range("PRICEFIN1").Select
ActiveCell.Offset(CYCINDX - 1, 0).Range("A1").Select
ActiveSheet.Paste
Range("DURB1").Select
ActiveCell.Offset(ITER, 0).Range("A1:I1").Copy
Range("DURBFIN1").Select
ActiveCell.Offset(CYCINDX - 1, 0).Range("A1").Select
ActiveSheet.Paste
Range("DRUR1").Select
ActiveCell.Offset(ITER, 0).Range("A1:I1").Copy
Range("DRURFIN").Select
ActiveCell.Offset(CYCINDX - 1, 0).Range("A1").Select
ActiveSheet.Paste
Range("TFOOD1").Select
ActiveCell.Offset(ITER, 0).Range("A1:I1").Copy
Range("TFOODFIN1").Select
ActiveCell.Offset(CYCINDX - 1, 0).Range("A1").Select
ActiveSheet.Paste
Range("TOTD1").Select
ActiveCell.Offset(ITER, 0).Range("A1:I1").Copy
Range("TOTDFIN1").Select
ActiveCell.Offset(CYCINDX - 1, 0).Range("A1").Select
ActiveSheet.Paste
Range("NIMP1").Select
ActiveCell.Offset(ITER, 0).Range("A1:I1").Copy
Range("NIMPFIN1").Select
ActiveCell.Offset(CYCINDX - 1, 0).Range("A1").Select
ActiveSheet.Paste
Range("LCYLD1").Select
ActiveCell.Offset(ITER, 0).Range("A1:F1").Copy
Range("LVCYLD1").Select
ActiveCell.Offset(CYCINDX - 1, 0).Range("A1").Select
ActiveSheet.Paste
Range("LPROD1").Select
ActiveCell.Offset(ITER, 0).Range("A1:F1").Copy
Range("LVPROD1").Select
ActiveCell.Offset(CYCINDX - 1, 0).Range("A1").Select
ActiveSheet.Paste
Range("LPRICE1").Select
ActiveCell.Offset(ITER, 0).Range("A1:F1").Copy
Range("LVPRICE1").Select
ActiveCell.Offset(CYCINDX - 1, 0).Range("A1").Select
ActiveSheet.Paste
Range("LVPCURB1").Select
ActiveCell.Offset(ITER, 0).Range("A1:F1").Copy
Range("LVPCURB1").Select
ActiveCell.Offset(CYCINDX - 1, 0).Range("A1").Select
ActiveSheet.Paste
Range("LDRUR1").Select
ActiveCell.Offset(ITER, 0).Range("A1:F1").Copy
Range("LVPCRUR1").Select
ActiveCell.Offset(CYCINDX - 1, 0).Range("A1").Select
ActiveSheet.Paste
Range("LFOOD1").Select
ActiveCell.Offset(ITER, 0).Range("A1:F1").Copy
Range("LVTFOOD1").Select
ActiveCell.Offset(CYCINDX - 1, 0).Range("A1").Select
ActiveSheet.Paste
Range("LTOTD1").Select
ActiveCell.Offset(ITER, 0).Range("A1:F1").Copy
Range("LVTDEM1").Select
ActiveCell.Offset(CYCINDX - 1, 0).Range("A1").Select
ActiveSheet.Paste
Range("LNIMP1").Select
ActiveCell.Offset(ITER, 0).Range("A1:F1").Copy
Range("LVNIMP1").Select
ActiveCell.Offset(CYCINDX - 1, 0).Range("A1").Select
ActiveSheet.Paste
Next
STOCHSW = Application.Range("WPSW") 'Value of stochastic switch
If STOCHSW = 1 Then Select JUMP2
Range("NOW").Select
Selection.Copy
Range("END").Select
ActiveSheet.Paste
SIMELAPSED = Application.Range("ELAPSED")
MsgBox "Simulation Run Completed, " & SIMELAPSED & " ELAPSED "
Range("DATERUN").Select
Selection.Copy
Range("RUNDATE").Select
ActiveSheet.Paste
JUMP2:
Range("OPTIONS").Select
End Sub
Sub ADELEFIN()
Range("AREAFIN1").Select
ActiveCell.Range("A1:J20").Select
Selection.ClearContents
Range("YLDFIN1").Select
ActiveCell.Range("A1:J20").Select
Selection.ClearContents
Range("PRICEFIN1").Select
ActiveCell.Range("A1:J20").Select
Selection.ClearContents
Range("DURBFIN1").Select
ActiveCell.Range("A1:J20").Select
Selection.ClearContents
Range("DRURFIN1").Select
ActiveCell.Range("A1:J20").Select
Selection.ClearContents
Range("TFOODFIN1").Select
ActiveCell.Range("A1:J20").Select
Selection.ClearContents
Range("TOTDFIN1").Select
ActiveCell.Range("A1:J20").Select
Selection.ClearContents
Range("NIMPFIN1").Select
ActiveCell.Range("A1:J20").Select
Selection.ClearContents
Range("LVCYLD1").Select
ActiveCell.Range("A1:J20").Select
Selection.ClearContents
Range("LVPROD1").Select
ActiveCell.Range("A1:J20").Select
Selection.ClearContents
ActiveCell.Range("A1:J20").Select
Selection.ClearContents
Range("LVPCURB1").Select
ActiveCell.Range("A1:J20").Select
Selection.ClearContents
Range("LVPCRUR1").Select
ActiveCell.Range("A1:J20").Select
Selection.ClearContents
Range("LVTFOOD1").Select
ActiveCell.Range("A1:J20").Select
Selection.ClearContents
Range("LVTDEM1").Select
ActiveCell.Range("A1:J20").Select
Selection.ClearContents
Range("LVNIMP1").Select
ActiveCell.Range("A1:J20").Select
Selection.ClearContents
Range("A1").Select
End Sub