morpheus
27th June 2002, 14:12
Hello,
I have an assignment wherein I need to update the standard BaaN tables from the barcodes. I can do it either by using DDC or API. But,I have used none. Can anyone help me on the issues like -
1. Which is better, DDC or API (I do not have source code, and the OS is Windows.). If some one has got any document/link on this topic, please inform.
2. Is source code required for DDC usage?
3. What is the use of Function Server Generator and to what extent is it helpful?

Thanks.

mark_h
27th June 2002, 16:27
I prefer the API type function servers and you do not need source for these. I have never done a DDC type function server so I am not sure if you need source or not. I have only worked on one DDC type function server and that was developed by Gordon - one of the other moderators. I have never used the generate function server session. I like the API method over the DDC type just so I do not have to mess with all the functions that get generated - at least that is what it seems like to me.

Here is a link (http://www.baanboard.com/baanboard/showthread.php?s=&threadid=889) to another post with some documentation on the API function servers. I use these function servers for things like mass inventory transfers, loading a simulation company, and even generating purchase orders. You can search the forum for API or STPAPI and read some of the other posts.

Good Luck!

Mark

gfasbender
27th June 2002, 19:44
When creating an interface to Baan, the important development aspect is to use existing Baan processing. This can be accomplished using either DDC Function Servers or API's (AFS, BOI). The differences between the two:

DDC Function Servers, 3GL sessions, are usually created from an existing 4GL session (leveraging existing code) by running the session tuddc9201m000 -Function Server Generator. Source code for the session you're converting is required if you want the functionality of the session. The generator basically converts the 4GL session into a 3GL session, removing all the GUI calls. This 3GL script then has to be compiled, creating a new object that can be called using BMS functions (Baan Message System). The downside is that if Baan releases an update to the source of the session you generated from, you will have to re-work your 3GL function server code and re-compile.

API's interface with existing Baan session objects through the API Handler. You're basically simulating the session being run by a user. You still have to create a script that makes the API calls you need. The script will also need to handle transaction I/O and error processing.

My preferred interface development method is of course API's.

nick_rogers
27th June 2002, 20:33
Is the API's only available in BaanIVc4 and up ?

For older versions of Baan I think just the DDC's are available.
You do not need the source code to generate the DDC function server. Baan supplies a standard set of DDC's , plus you can genaerate additional DDC's based on sessions for which you do not have the source. To actually compile them only one DDC include function is required for which the source is present on all envs........

But you do need to tweak the generated DDC source as Baan does not successfully remove the GUI code such as set.input.error's and choice.again's.

The other possible solution is to call a Baan DLL that might be available for the function, use the display DLL seesion to what there is.....ie tdpurdll1234 generates a P.O and line(s).

mark_h
27th June 2002, 23:18
I believe the API is available for all 4c versions - we are on 4c3. I also think it is available for some of the 4b versions, but I am not positive.

Mark

Richard Chan
28th June 2002, 04:41
Hi,
I am also interested in connecting barcdoe scanners to Baan IV through DDC.
I was told that the only program that I need to make is the ddc driver (this is the one that makes the hardware "talks" to the DDC).
Any sample driver program available will be apprciated.

Richard

morpheus
28th June 2002, 07:34
Hello,
Thanks for the timely response.
It seems that source code is required for DDC functionality. So, I think I'll go ahead with the API thing.
Will ask for your services again.
Till then...good luck.

lbencic
12th July 2002, 00:10
The DDC is specific for Bar Code scanning, mostly. DDC code is ment to run through the DDC module, which does logging, etc, for communication with remote handhelds. There is another piece needed called 'middleware' to communicate with baan and run the handhelds. That is a 3rd party product. My company has one (rmc3), and so do several other vendors - Connectware, etc. Baan is/was working on their own - Wonderware...not sure of the status there.

Also, Nick, I beg to differ. You usually need the source code for your target session to use the DDC generator.

We have found methods of developing DDC's without source code using the generator, but you need our conversion program to run this. It is based on similar logic to the stpapi's, in that the standard program sections are called instead of the code itself. This greatly reduces the DDC risks as far as Baan updating the standard code and your DDC code not being updated.

Just some more food for thought. I would not use the DDC's unless you have need of the DDC Module/Bar Coding requirements.

nick_rogers
16th July 2002, 15:49
Hi lbencic - to generate DDC without having the actual source code for the session - I have used the Function Server Generator (tuddc9201m000) which is a standard Baan session. It generates a DDC script for the given sesssion - it pulls all the code that is present in the session/include fuctions. The only include function needed is the "ituddc0010" which handles the DDC logs as prev noted in this thread (most installs have this include function - or Baan will provide it). The generated script then has to be modified to remove the GUI code such as set.input.error etc....

If this is what you are referring to as needing source code ? then I agree............but you do not need the source code of the session that you wish to convert...

lbencic
16th July 2002, 17:17
Nick -
If you generate on a session that does not have the source, you get a generic table update based on the form fields and main table for the session. You do not get the session code - how could it get the source if you do not have it? Try a generate with and without source and see the difference. Are you referring to Baan IV or V? In Baan V, maybe they call DAL updates on the table, so you are getting the DAL logic (not the session logic). In Baan IV, you don't get any business logic without the source. That is true at least for the version I have.

With or without the session logic, you only need the ituddc0010 source to compile your ddc code after generating, which Baan will send you. You can write your own ddc code without the generator, and only need ituddc0010 to compile & run, so you don't really need source to develop ddc's, just the generator part.

To get the session logic using the ddcs without source, you can use the stpapi's or similar coding. Maybe the ddc generator should be changed to use these so you don't need the source to get all the session logic, it is a very logical next step. When I referred to a method we have, this is how we do it.

nick_rogers
16th July 2002, 17:41
lbencic - In BaanIVb and even BaanIVc versions the business/presentation is within the session it is not split up as in BaanERP (DAL etc...).

I am on BaanIVb2 - I just generated a function server for the tdsls4101m000 session for which I do not have source. The generated script has all fuctionality of the session/includes.
I suspect that baan reads the psudo object- that is why is can generate the code.
We did this for an actual project and deployed the DDC's in prod.

patvdv: <text removed for privacy reasons>

patvdv
16th July 2002, 18:02
I am closing this thread for discussion.