If statement not working?
Hey guys,
I have a if/else statement which works on the first 2 criteria in green (150mm Adjustment and 100mm Adjustment), but fails on the last when no criteria has been met. I must be missing something very simple. Can anybody help me please? It will be greatly appreciated. Please see below.
- /////////////////////////////////////////////////////////////////////
// 150mm Adjustment
/////////////////////////////////////////////////////////////////////
if(input.ctwSampleDimensions = "150")
{
if(spl.sampleGNGResult = "Fail" && spl.sampleGNGFailProcessing = "Complete")
{
if(spl.stage2Result = "Fail")
{
if(spl.sampleGNGReportHold = "Hold")
{
if(spl.sizeCheckSubform.stage1Result = "Fail")
{
spl.stage2MaxLoadRpt=input.stage2MaxLoadRpt;
spl.stage2FailingLoadRpt=input.stage2FailingLoadRpt;
spl.stage2AverageArea=input.stage2AverageArea;
spl.stage2MaxLoadAdjusted=input.stage2AdjustedMaxLoad;
spl.stage2CompressiveLoadAdjusted=input.stage2AdjustedCompressiveStrength;
spl.stage2MaxLoadOriginal=input.stage2MaxLoadOriginal;
spl.stage2FailingLoadOriginal=input.stage2FailingLoadOriginal;
spl.sampleGNGReportHold="Complete";
}
}
}
}
}
/////////////////////////////////////////////////////////////////////
// 100mm Adjustment
/////////////////////////////////////////////////////////////////////
else if(input.ctwSampleDimensions = "100")
{
if(spl.sampleGNGResult = "Fail" && spl.sampleGNGFailProcessing = "Complete")
{
if(spl.stage2Result = "Fail")
{
if(spl.sampleGNGReportHold = "Hold")
{
if(spl.sizeCheckSubform.stage1Result = "Fail")
{
spl.stage2MaxLoadRpt=input.stage2MaxLoadRpt;
spl.stage2FailingLoadRpt=input.stage2FailingLoadRpt;
spl.stage2AverageArea=input.stage2AverageArea;
spl.stage2MaxLoadAdjusted=input.stage2AdjustedMaxLoad;
spl.stage2CompressiveLoadAdjusted=input.stage2AdjustedCompressiveStrength;
spl.stage2MaxLoadOriginal=input.stage2MaxLoadOriginal;
spl.stage2FailingLoadOriginal=input.stage2FailingLoadOriginal;
spl.sampleGNGReportHold="Complete";
}
}
}
}
}
// Below doesn't execute
- spl.stage2MaxLoadRpt=input.stage2MaxLoadRpt;
spl.stage2FailingLoadRpt=input.stage2FailingLoadRpt;
Access your files securely from anywhere
Zoho Developer Community
Deliver unforgettable customer experiences
Deliver unforgettable customer experiences
New to Zoho Marketing Plus?
Everything you need to run your marketing
New to Zoho Marketing Plus?
Everything you need to run your marketing
Zoho Desk Resources
-
Desk Community Learning Series
-
-
-
-
-
-
-
-
-
Zoho TeamInbox Resources
Zoho DataPrep Resources
Zoho CRM Plus Resources
Zoho Books Resources
Zoho Subscriptions Resources
Zoho Projects Resources
Zoho Sprints Resources
Qntrl Resources
Zoho Creator Resources
Zoho Campaigns Resources
Zoho CRM Resources
Zoho Show Resources
Writer Get Started. Write Away!
Writer is a powerful online word processor, designed for collaborative work.