vba - Crystal Report XI error in formula using Basic Syntax " 'THEN' Missing " -


i getting error 'then' missing if play around formatting highlight else if way down formula = line.

i have attached screenshots show mean highlight. have come realize crystal report finicky formatting sometimes, can provide insight or correct approach formula working?

thanks in advance!

 dim qtyavailable number    if isnull({hb_available_qty_sku\\.avail})      qtyavailable = 0          else if ({hb_available_qty_sku\\.avail}) = 0                 , ({inventory_part\\.prime_commodity})                  fly* or spc*          "na"               else if {shop_material_alloc\.qty_required} = {shop_material_alloc\.qty_assigned}              qtyavailable = {hb_available_qty_sku\\.avail}+{shop_material_alloc\.qty_assigned}                  else qtyavailable = {hb_available_qty_sku\\.avail}                 end if          end if  end if  formula = qtyavailable 

else if error crystal reports

you need have "then" on same line "if" modified pseudocode of if statement similar to:

if isnull({foo})      qtyavailable = 0 else      if ({foo}="0" , {foo} "1")          ' nothing     else          if {foo} = {bar}               qtyavailable = 2         else              qtyavailable = 3         end if     end if end if 

Comments

Popular posts from this blog

get url and add instance to a model with prefilled foreign key :django admin -

css - Make div keyboard-scrollable in jQuery Mobile? -

ruby on rails - Seeing duplicate requests handled with Unicorn -