Variable order

Dedicated forum for the visual 'drag and drop' voice application designer that allows easy creation of advanced voice applications without programming knowledge

Moderators: kevin, 3CX staff

Variable order

Postby SWSDEV » Wed Mar 17, 2010 5:14 pm

When passing in variables to a .net library, how does it determine the order of the variables?

I have 5 variables in a code component, and I have them in the same order in my vad component and with the same names, but they're getting passed in to the function in a different order.
Shahzad Qureshi
SWS Development - 3CX Certified Partner
Custom 3CX integration
Salt Lake City, UT USA
801-938-7712
swsdev.com
SWSDEV
Expert
Expert
 
Posts: 246
Joined: Sat Feb 23, 2008 6:51 am
Location: Salt Lake City, Utah - USA

Re: Variable order

Postby SWSDEV » Wed Mar 17, 2010 5:28 pm

Looks like variables are actually passed in, inreverse order.
Shahzad Qureshi
SWS Development - 3CX Certified Partner
Custom 3CX integration
Salt Lake City, UT USA
801-938-7712
swsdev.com
SWSDEV
Expert
Expert
 
Posts: 246
Joined: Sat Feb 23, 2008 6:51 am
Location: Salt Lake City, Utah - USA

Re: Variable order

Postby VAD_Support » Wed Mar 17, 2010 6:14 pm

Hi,

Variables are passed to the library in the same order specified in the configuration of the component. Can you send me the callflow file to review it? I have tested this here and works, so maybe there is something wrong in the configuration...

Thanks,
VAD_Support
3CX Valued Professional
3CX Valued Professional
 
Posts: 421
Joined: Thu Aug 06, 2009 5:29 pm

Re: Variable order

Postby SWSDEV » Wed Mar 17, 2010 8:36 pm

What I did was I attached the Visual Studio debugger to the IIS worker process and the variables always came in the opposite order that they were specified in the VAD designer.

However it only did this for is one component, which is odd.

I will send you the files so you can take a look.

Should I just attach it here to a private message?
Shahzad Qureshi
SWS Development - 3CX Certified Partner
Custom 3CX integration
Salt Lake City, UT USA
801-938-7712
swsdev.com
SWSDEV
Expert
Expert
 
Posts: 246
Joined: Sat Feb 23, 2008 6:51 am
Location: Salt Lake City, Utah - USA

Re: Variable order

Postby VAD_Support » Wed Mar 17, 2010 8:44 pm

Yes, please attach it to a private message, so I can take a look at it.
Also, can you send me the generated ASPX output for the component? That way I can see if variable order is right in code, or if it has been changed there...
Thanks.
VAD_Support
3CX Valued Professional
3CX Valued Professional
 
Posts: 421
Joined: Thu Aug 06, 2009 5:29 pm

Re: Variable order

Postby SWSDEV » Wed Mar 17, 2010 10:27 pm

OK, I will get this to you later this evening.
Shahzad Qureshi
SWS Development - 3CX Certified Partner
Custom 3CX integration
Salt Lake City, UT USA
801-938-7712
swsdev.com
SWSDEV
Expert
Expert
 
Posts: 246
Joined: Sat Feb 23, 2008 6:51 am
Location: Salt Lake City, Utah - USA

Re: Variable order

Postby VAD_Support » Wed Mar 17, 2010 10:30 pm

Thanks!
VAD_Support
3CX Valued Professional
3CX Valued Professional
 
Posts: 421
Joined: Thu Aug 06, 2009 5:29 pm

Re: Variable order

Postby VAD_Support » Wed Mar 31, 2010 8:07 pm

Hi Shahzad,

I've been looking at the files you sent me, and doing some testing with the VAD, and it seems that variables are passed to the external component in alphabetical order. This is a bug in the VAD that we'll fix as soon as possible.

Until we release this fix, something you can do to avoid having this problem is renaming the parameters, for example adding a prefix in alphabetical order ("p01_", "p02_", etc.). This way, parameters will be passed in the order you need.

Thanks for reporting this error, we'll work on a fix and maybe in a couple of weeks we can release a new version...
VAD_Support
3CX Valued Professional
3CX Valued Professional
 
Posts: 421
Joined: Thu Aug 06, 2009 5:29 pm

Re: Variable order

Postby SWSDEV » Thu Apr 01, 2010 8:19 am

Thank you
Shahzad Qureshi
SWS Development - 3CX Certified Partner
Custom 3CX integration
Salt Lake City, UT USA
801-938-7712
swsdev.com
SWSDEV
Expert
Expert
 
Posts: 246
Joined: Sat Feb 23, 2008 6:51 am
Location: Salt Lake City, Utah - USA


Return to 3CX Voice Application Designer (VAD)

Who is online

Users browsing this forum: No registered users and 0 guests