My bad, i forgot to write the $chan in the /writeini.
The correction of your code would be like this:
Code:
if ($1 == .orders) { 
  if ($2 == $null) { msg $chan Orders for #channel: }
  elseif ($2 == set) {
    .writeini Orders.ini $chan $calc($ini(Orders.ini,$chan,0) + 1) $3-
    notice $nick The Line was saved into Orders.ini with the channel: $chan and the Orders you specified.
  }
}


Nothing...