Automatic run adjust cost item entries at night

I have more than 200,000 items in my database. I have to run adjust cost item entries every day. (I use function from ‘Periodic Activities’ → ‘Adjust Cost - Item Entries’ menu) I want to know that Can i run it by automatically at night time?

if in your system available, you can solve it by application server

Sorry. i forgot to tell you about the detail of my environment. i use navision attain version 3.6 on SQL server 2000.

3.60 Comes with a Scheduler (In Service). You should be able to use this out of the box to run a report (795 in this case).

Thanks Chris. It means i have to buy service management granule,Right?Do you have any recommendations if i didn’t buy this granule?[:)]

Maybe you could do something with the timer trigger on a form to start something “scheduled”, but it sounds messy. The Job Scheduler option is probably the best approach.

quote:


Originally posted by dttj
Thanks Chris. It means i have to buy service management granule,Right?Do you have any recommendations if i didn’t buy this granule?[:)]


You could do something like this (it’s not a very detailed explanation, but I hope it gives You some hints): Create a table where You put in the dates and times when You want’t the adjmt done. Here You also can put in some parameters such as dates and such. Create a single instance codeunit (a property on the codeunit) where You use Navisions timer (an automation object which You can read about in other postings here). Call this codeunit in trigger 99 (AppHandler) in codeunit 1 so it starts when You launch nassql.exe with Your own startupparameter. Your codeunit should then look in the table (lets say every minute) to see if its time to do something. If it is You start the standard objects for adjustment and posting of adjustments but pass some parameters for dates and so on. Don’t forget to set up printer selections for the user running NAS so You get the posting report out on a printer.

Impressive Lars ! But how can you get the system to search that table every minute ?

When You declare the NTimer.dll as an variable You automatically get new triggers to use in Your coudeunit. Quite a nice feature… BTW: The table NAS should poll can easily be extended to handle mote than just cost adjustments. This is a way to schedule other tasks as well.