Automated Warehouse Receipt Posting

Guys, I’ve written a warehouse interface which automatically posts warehouse receipt lines when the warehouse receives the stock. I have a problem where the posting codeunit fails (running using a NAS) and I can’t identify the problem. I need to write some validation code to ensure that the warehouse receipt can post, this includes checking all the various fields which the posting codeuint checks (posting groups, dates etc). Has anyone already written such a function? It would save me a lot of time if they could send me a list of fields to check or a txt field containing the function. Thanks, Alex.