shriram
10th May 2007, 18:04
Hi,
Is there a way to specify which user name to be logged on with when using the default BW in OLE automation.
Typically we can change users in command line in BW config. Is there a way to specify the command line in OLE automation?
Thanks for your help and support.
Regards
Shri
mark_h
10th May 2007, 18:56
Is it possible to keep a different .bwc file used only for ole automation? Or maybe just add the command line to the .bwc file before running? Below are commands in one of my .bwc files - I could probably replace the command line with something different, save it, and launch it. There might be another way but this is what popped into my head.
[ApplicationServer]
bse=/apps/baan/baaniv/bse
bshell=bshell
command=-- -set DDC_DELIMITER=| -set DDC_UPDATE=YES -set DDC_TIMER=9999 -set SITE=660
location=
connection=
shriram
10th May 2007, 22:26
Thanks Mark,
The problem is two-fold:
1. Baan Automation launches the BW file that is categorized as "Default" in BECS. So the possibility of having multiple BW configurations for different user names and passwords and being defaults is not possible.
2. We are trying to launch this from a .NET script, so the possibility of changing the BW command line at runtime seems difficult.
The objective is that each user that logs on to the .NET application and connects to Baan to update a table then this connection to Baan should use the user's Baan user name and password so that the audit on the changes is still retained in Baan.
Can we configure the BW command line as an argument in OLE automation?
Thanks,
Regards
Shri
mark_h
11th May 2007, 06:12
Thanks Mark,
The problem is two-fold:
1. Baan Automation launches the BW file that is categorized as "Default" in BECS. So the possibility of having multiple BW configurations for different user names and passwords and being defaults is not possible.
2. We are trying to launch this from a .NET script, so the possibility of changing the BW command line at runtime seems difficult.
The objective is that each user that logs on to the .NET application and connects to Baan to update a table then this connection to Baan should use the user's Baan user name and password so that the audit on the changes is still retained in Baan.
Can we configure the BW command line as an argument in OLE automation?
Thanks,
Regards
Shri
Well for (1) I did not know that - I have only used it in some VB code with Excel. In using that I could specify which .bwc was used. And (2) is out of my league. I am not sure about the bw command line arguments - you might want to search the board for command line options. I think I have a post book marked and when I get to work tomorrow I will look for it.
mark_h
11th May 2007, 06:19
Check this thread (http://www.baanboard.com/baanboard/showthread.php?t=95&page=3&highlight=bw.exe+command) and see if it helps.
shriram
11th May 2007, 17:45
Thanks Mark,
I will try and check out the possibility of launching specific bwc. Do you have sample code for the same?
Do we just mention the class name as "Baan.Application.<specific>"?
Thanks,
Regards
Shri
mark_h
11th May 2007, 17:55
Set BaanObj = CreateObject("Baan4.Application.503") - where .503 is the company I was logging into. On the automation tab on the bwc file this is where I name them.
shriram
14th May 2007, 21:41
Hi Mark,
Thank you very much for your input. I finally got it working with your suggestion.
Regards
Shri