spacer
cornerspacercorner
Reply
Occasional Visitor
Tobsey
Posts: 1
Registered: 12-08-2011
0 Kudos

Calling functions in other JScript.Net files

Hi

 

I have a procedure that uses two libraries. Each of the Libraries contains a single JScript.Net file. One is for accessing custom configuration values and the other is for looking up Active Directory.

 

In the procedure I have a JScript.Net file also. Is it possible to call functions in my Configuration and Active Directory script files from the procedure JScript.Net file. I've tried importing the namespaces of my library scripts into the procedure script but it doesn't work. I've also tried fully qualifying the method name. Either way the script will not validate and therefore not publish.

 

In my situation the two library scripts are used to get the a user's email address and send them an email based on a template in the custom configuration. I know I could retrieve the values I want from the library scripts into custom variables and then pass them into my procedure script functions as parameters it would be easier to just copy and paste the library script functions into my procedure script, which pretty much makes the libraries worthless, except as code repositories.

 

Thanks

Occasional Contributor
Sam Judson
Posts: 4
Registered: 05-20-2010
0 Kudos

Re: Calling functions in other JScript.Net files

You could always call ework.Script (or ework.ScriptEval) to call the other script.

Valued Contributor
Paul
Posts: 144
Registered: 05-19-2010
0 Kudos

Re: Calling functions in other JScript.Net files

Version 7, ah that takes me back!

 

This was always a problem with v7 that namespaces from other server-side scripts would not validate but so long as they were correct you could ignore them.

 

The reason you cannpt publish is likely to be becasue of your publish settings in designer. Go into the options and set designer so that you can ignore validation errors when publishing.

 

Hope this helps.

line spacer line
spacerFollow Metastorm on:
spacer Twitter YouTube Blog iTunes LinkedIn Metastorm Community Central, MC2
spacer Copyright © 2011 OpenText Corporation. All Rights Reserved.spacer About Metastormspacer Privacyspacer Legalspacer Site Mapspacer RSSspacer Contact Us
Microsoft Gold Certified Partner
Powered by Windows Azure
line spacer line