Execution of scripts was prohibited. Use the XsltSettings.EnableScript property to enable it

Hi,
I have created a custom field in SharePoint 2010. I have a xsl file which does the Xslt rendering for item display in list view. I need to add some C# code to the xslt code. So i included code as below:
1)
xml:user="urn::my-scripts" in the xsl:stylesheet tag.
2)
<msxsl:script language="C#" implements-prefix="user">
    <msxsl:assembly name="System.Web"/>
    <msxsl:using namespace="System.Web"/><![CDATA[public string GetDate(string DateFormat){return DateTime.Now.ToString(DateFormat);}]]>
  </msxsl:script>
3) And used it in the code as
<xsl:value-of select="user:GetDate('dddd, dd MMMM yyyy')"/>
But, i get an error saying:
Execution of scripts was prohibited. Use the XsltSettings.EnableScript property to enable it. An error occurred at C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\template\layouts\xsl
Since its a custom field, i have only the XML file to declare the custom field and the XSLT to render it, when it comes to displaying in a list item view. 
Though in some scenario's the XmlTransform class is used to set the XsltSettings.EnableScript
property through a C# code file, here it doesn't seem to be feasible.
Is there a way to set the EnableScript property in the XSLT or XML ? Or any other ways ? 

Hi Elena,
The issue is caused by XSLT is not script enabled by default.  Please provide XsltSettings in the loading to fix the issue. For more information, please see:
http://daomingworks.wordpress.com/2009/12/11/xslt-transform-data-error-use-the-xsltsettings-enablescript-property-to-enable-it/
Thanks,
Jinchun Chen
Jinchun Chen
Forum Support
Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact tnmff AT microsoft.com(Please replace AT with @)

Similar Messages

  • I have two apple id accounts ,when i used to update application it used to prompt a default id and if the application was downloaded using the other id i would cancel and it would prompt the other id but not any more .

    i have two apple id accounts ,when i used to update application it used to prompt a default id (the old one) and if the application was downloaded using the other id i would cancel and it would prompt the other id but not any more .
    it just prompt the old id which im not signed in with im signed in using the new id and when i cancel nothing happens and when i try to update applications separately  i have the same problem .
    im signed in using the new id
    the old one is my wife's so i can't delete it
    the problem happens  when i update all or  each application by its own
    using ios 5.0.1 on a iphone 3gs
    the applications are downloaded using both the new and old id's
    any help will be greatly appreciatedِ

    These are user-to-user forums, you are not talking to Apple here and they don't monitor these forums - I've asked the hosts to remove yout account ids from your post.
    In terms of combining accounts it's not currently possible to do so, nor to copy/transfer content from account to another.

  • How to remove preinstalled files of adobe photoshop from my mac mini so that i can install a new version of the same software.The previous version was removed using the app cleaner software.Could not continue installation bcoz of earlier files

    How to remove preinstalled files of adobe photoshop from my mac mini so that i can install a new version of the same software.The previous version was removed using the app cleaner software.Could not continue installation of the new version because of the existance of files from the previous version.plz help

    What "app cleaner software" ? I ask because installing Photoshop over a previous version has never been a problem. Perhaps your difficulty stems from another source, eg. "cleaner software" ?
    If you look in your hard drive, at the root level there is a Library. In there is a folder called Application Support, and in that you will find a folder called Adobe. Files from your previous version are there.
    However, I urge you to call Adobe support to make sure you are not doing anything that would mess up other Adobe applications.
    http://www.adobe.com/support/connect/connecthostedsupport.html

  • I have my iPhoto set to an external drive yesterday when it was in use the usb disconnected i now have a message saying (your photo library is either in use by another application or has become unreadable) I have tried shutting down and restarting.

    I have my iPhoto set to an external drive, when it was in use the usb disconected as i was moving my mac air, when i re-conected a message said (your photo library is either in use by another application or has become unreadable).
    I have tried shutting it down and then re opening iPhoto but get the same message.
    The reason for the external drive was there was not enough room on my hard drive, I have around 7000 photos on it.
    is there a simple fix?
    Regards
    Dale

    These are your options:
    1. Restore the iPhoto library from the most recent backup that predates the issue.
              Advantages: Always works, if library damage is causing the problem and the backup is intact.
              Disadvantages: Impossible if you don't have a backup. All changes made since the backup are lost.
    2. Repair or rebuild the library. Be sure to back it up first.
              Advantages: May solve the problem with no loss of data.
              Disadvantages: May fail. May take a long time if the library is large.
    3. Scavenge the library with a third-party application called "iPhoto Library Manager," which you can find in a web search. From the application's menu bar (not the iPhoto menu bar), select Library ▹ Rebuild.
              Advantages: All images and albums should be preserved.
              Disadvantages: All books, calendars, and slideshows will be lost.

  • I was not using the cellular data on my Ipad, yesterday I reset my account to start using it again but i can't, please help!!!!!!

    I was not using the cellular data on my Ipad, yesterday I reset my account to start using it again but i can't, please help!!!!!!

    I was going to say either that or to remove the email from your email account settings(on ipad) and put it back on. Happens everytime im forced to change my work email password. I need to delete the account and add it again for it to accept the new password.

  • How would I use the blur filter property

    I commented out the alpha line in my script but I would like to use the blur filter property.
    My animation seams a bit abrupt an easing effect can that be doe or not ... if so how?
    Please take a look at the attached pictures for more detail ... thank you.
    TX
    var dir:int = 1;
    var T:Timer = new Timer(1);
    T.addEventListener(TimerEvent.TIMER, flap);
    function flap (Event:TimerEvent):void
    dragonfly_mc.wings_mc.scaleX += .05 * dir;
    if ((dragonfly_mc.wings_mc.scaleX>=1&&dir>0) ||
    (dragonfly_mc.wings_mc.scaleX<=.3&&dir<0))
    dir*=-1;
    //dragonfly_mc.wings_mc.alpha = .3;
    //import flash.filters.BlurFilter.quality;
    Event.updateAfterEvent();
    T.start ();

    var dir:int = 1;
    var t:Timer = new Timer(1);
    //var bf:BlurFilter = new BlurFilter
    //(10, 10, BitmapFilterQuality.HIGH);
    //var gf:GlowFilter = new GlowFilter
    //(10, 10, BitmapFilterQuality.HIGH);
    import fl.transitions.Tween;
    import fl.transitions.easing.*;
    import fl.transitions.TweenEvent;
    var blurX:Number = 80;
    var blurY:Number = 80;
    var bf:BlurFilter = new BlurFilter(blurX,blurY);
    var tw:Tween = new Tween(bf,"blurX",None.easeNone,0,30,1,true);
    t.addEventListener (TweenEvent.MOTION_CHANGE,f);
    function f (e:Event)
    bf.blurY = bf.blurX;
    dragonfly_mc.wings_mc.filters = [bf];
    t.addEventListener (TimerEvent.TIMER, flap);
    function flap (Event:TimerEvent):void
    dragonfly_mc.wings_mc.scaleX += .05 * dir;
    if ((dragonfly_mc.wings_mc.scaleX>=1&&dir>0) ||
    (dragonfly_mc.wings_mc.scaleX<=.3&&dir<0))
    dir*=-1;
    //dragonfly_mc.wings_mc.filters = [bf, gf];
    //dragonfly_mc.wings_mc.alpha = .2;
    //import flash.filters.BlurFilter.quality;
    Event.updateAfterEvent ();
    t.start ();

  • How do I use the Index Values property node with a multidimensional array.

    I am using a 2D array to store operator inputs on my front panel.  I only want to display one element to the operator at a time.  I am trying to use the Index Values property node to change the displayed element.  However, I can only get the Rows index to work.  How do I direct the Columns index as well?  The help says to use one per dimension.  I need clarification on what this is talking about.  I've tried adding a second element to the property node, 2 seperate property nodes, and diferent wiring techniques. (series, parallel)

    If you only wire up one of the inputs (col or row) what you get out is a 1D array of either the column or row. If you wire controls to both, then you will get one element out of the array. Getting a single element in a 2D array requires you to specify both a row and column.
    Message Edited by Dennis Knutson on 02-08-2007 08:34 AM
    Attachments:
    Index 2D Array.PNG ‏2 KB

  • After installing an application that was created using the Application Builder

    After installing an application that I created using the Application Builder I get this error if I try to run " ANY " LabVIEW App's that I have built. "Executable Version 7.1.1 doesn't match Resource File 7.1. Check your configuration."
    The way that I tried to fix this is to reload LabVIEW 7.1 and DAQmx 8.0. I am using two NI-6528 switch cards.
    After I reload LabVIEW and DAQmx I can run my applications but as soon as I install one on this development machine the error begins again.
    The executable that I built works fine on the development machine and any other machine that I try it on but it appears that the Run-Time engine 7.1 becomes corrupt after I run setup.exe for the newly created application.
    I have built numerous Installers, setup.exe's in the past without this error. Just this latest one caused this problem to start.
    I can NOT upgrade to 7.1.1. I am doing work for many different sections of this factory and I can not force them to upgrade. I've asked. Others supply code for the same machines using LabVIEW 7.1.
    I am stuck creating executables and manualing moving the correct files to the target machines.
    What can be done?

    No. The KB article was talking about a machine with 7.1.1 installed. I have LabVIEW 7.1 installed.
    The machine that I am having trouble with is my development machine. LabVIEW 7.1, DAQmx 8.0.
    If I build the executable all is fine. I can still run old executables including the one I just built.
    If I create the installer all is fine. I can still run old executables including the one I just built.
    When I install the app on my development machine the corruption occurs. I can " NOT " run old executables including the one I just built. The subject error pops up.
    I have not moved any executables to the other machines yet. I don't want to corrupt others.

  • I restore my iPhone 4S on iTunes and then when restarted it is asking for valid SIM card and I don't have SIM card for that, I was just using the iPhone with wifi, any one can help? Please.

    I restore my iPhone 4S on iTunes after the restore was completed the iPhone was restarted and now asking for valid SIM card which I didn't,t have and I was using the iPhone with wifi, and now can't use it because the screen is locked for SIM card. Can anyone help me please.
    Thanks,
    David

    wjosten wrote:
    Phil0124 wrote:
    I doubt the phone is locked to GCI in any way
    Well, you're wrong, & in fact not only is it locked, GCI does not offer unlocking for iPhones.
    Fact is your post won't help the OP.
    And you are 100% sure its locked to them? How can you know this? While GCI does not offer unlocking that does not mean the phone is actually locked to it. Get off your high horse.
    Its possible the original owner had an unlocked phone. he was using with GCI. Or that GCI doesn't actually have locked phones. Seeing as they don't even have their own infrastructure but instead use AT&T's I doubt they'd have iPhones specifically locked to them and that would be the reason they do not offer unlocking (because there's nothing for them to unlock). And just to clarify, I'm not saying for a fact its not locked to them. It very well maybe be, but without knowing more about the phone and going by the fact GCI uses AT&T infrastrucure its possible its not locked. But here's no way to say for sure either way.
    Trying a Sim card from AT&T or another carrier might just help the OP if its actually unlocked or locked to AT&T rather than GCI.

  • Is it possible to change the first page of a web application that was built using the UI?

    Hello Community
        Using Sharepoint 2010 Server and the UI I built and application and would like
    to continue building the web application using the UI.
        The application's first page was built using a Blank Site template and
    the subsequent subsites were built using the Team Site template.
        In retrospect the first page should also have been built using a Team Site template.
        It may be unnecessary to make to delete the application
    and create the first page as a Team Site and then have to create all of the
    subsites (Team Sites) all over again.
        As a solution to prevent deleting the whole application and creating application
    with all of the subsites all over again whether it is possible to do any of the
    following:
        - Convert the Blank Site page into a Team Site page which would allow
    me to leave all of the subsites as is.
        - rename the Blank site page which would in effect would be renaming the application
    then create a new Team Site page which would be essentially creating a new application and
    then adding all of the subsites contained in the renamed application that has the first page
    as a Blank page.
        And if is possible to add, copy or move the subsites from existing sites to a new Team Site
    page, how do you add, copy or move the subsites from one application to a diffent application?
        Thank you
        Shabeaut

    Hi Shabeaut,
    According to your description, my understanding is that you want to change the template of the root site without creating the susites in another web application.
    I recommend to export all the existing subsites and import them to new web application.
    More references:
    http://social.technet.microsoft.com/Forums/sharepoint/en-US/cc7c11ec-e4da-4ddb-babd-db76ccb35664/move-subsite-to-new-site-collection?forum=sharepointadminprevious
    http://social.technet.microsoft.com/Forums/sharepoint/en-US/fd321bac-16a7-47e4-842e-00b7ca0f7f05/move-subsite-to-other-site-collection-as-subsite?forum=sharepointadminprevious
    Best regards.
    Thanks
    Victoria Xia
    TechNet Community Support

  • Ora-26040 : data block was loaded using the NOLOGGING option

    i have restored full back up database using RMAN sucessfully from one server to another .Restoration process do not contain any error.
    New Database contain job when it executes then it leaves mesaage in alert log.
    "ORA-01578 oracle data block corrupted file # 6 block # 6888812"
    "ORA-26040 data block was loaded using nologging option".
    please let me know how it could recovered and prevented.
    regards
    prabhat

    In short, your full backup has happened when a NOLOGGING transaction was on flight. Hence the recovery process should get the transaction's data out of archive logs. BUT the data doesn't exist in archivelog beause the transaction was NOLOGGING. For comprehensive detail read the documents above.
    To prevent this situation, backup the database when no NOLOGGING transaction is running.

  • I tried to give feedback & I was told I was not using the latest version of Firefox. I upgraded, restarted my computer, then I got the same response. Therefore, I can't give feedback.

    Here's my feedback: Make it easier to make Firefox your default browser. I shouldn't have to use a help menu to figure this out.

    @sjpierce - I don't believe that this is a Firefox-specific issue, but it does sound like you have some sort of malware on your machine. What was this innocuous link that you clicked on? A lot of viruses and malware make their rounds on Facebook.
    Regardless, what I would do is this ( I assume you're running Windows):
    * Download the Free and awesome Microsoft Security Essentials (MSE) via [http://www.microsoft.com/security_essentials/ http://www.microsoft.com/security_essentials/]
    * Next update MSE and do a full system scan to ensure you don't have any existing malware on your machine. If so, clean it off and reboot. Keep doing this until you come up clean.
    * Refer to this article on SUMO [[Profiles|Profiles]]
    * Delete your old Firefox profile, create a new one and launch Firefox 4 again using the new profile
    You should be back to normal at this point.
    If you are running an OS like Mac OS X or Linux, it's unlikely that you have malware and you should probably clean your Firefox profile and start over again.

  • Apple Script / Script Editor to use the mouse

    Hi
      Can you write a script in script editor to move the mouse to specific coordinates and click. If so could you please write a simple script to move the mouse to coordinates {800, 310} and then click a button. Second is there a way to select an account and log in. If so can you please write a few lines to show me.Thanks.

    Hi Carol,
    You need System Preferences>Universal Access>"Enable Access for Assistive Devices" checked for this to work, and of course if it isn't a Finder button you'd change something...
    activate application "Finder"
    tell application "System Events"
      tell process "Finder"
      click at {800, 310}
      end tell
    end tell
    Or if you want to use Terminal...
    http://www.hamsoftengineering.com/codeSharing/MouseTools/MouseTools.html

  • I was previously using the free trial which expired, so i bought the software. However, it is not registering that i am now a member and keeps saying that my free trial has expired.

    What do I do?

    download the cc desktop app and sign in with the same adobe id used to subscribe:  Download Adobe Creative Cloud apps | Free Adobe CC trial
    if you still see that problem, uninstall your trial and install using the cc desktop app.

  • Can I use the 'Export Signal Property Node' on a quadrature encoder?

    Hi,
    So I don't know which counter board I'd be using yet for this (it's used in conjunction with a PCI-6280--the PCI-6280's counter inputs are all taken and so I need another board), but assuming this is possible at all in DAQmx I wouldn't mind knowing whether, say, the PCI-6601 (or any other timer board for that matter) could do this. I'm programming this in LabVIEW 2010 by the way. 
    I want to have a counter which counts the number of pulses on one channel (I'll call this the 'clock' channel) between when another channel goes from low to high (which I'll call the trigger). It's basically a pulse width measurement, but I only care if there are more than n clock pulses between triggers. I need to have a hardware-timed digital signal which goes from low to high if there are ever more than n pulses between trigger changing state from low to high. 
    What I am planning to do is this: 
    Wire 'trigger' to the z-input of the quadrature encoder, and set the z-input value to some arbitrary large value such that, at the quadrature encoder counter task's settings, the counter reaches terminal count in n pulses.
    Configure the quadrature encoder counter using DAQmx Export Signal Property Node (tutorial I was looking at is here: http://zone.ni.com/devzone/cda/tut/p/id/5387 ) to toggle a digital channel ('counter event output') from low to high if the counter reaches terminal count (ie, if the encoder reads n pulses).
    If the encoder ever reads n pulses on 'clock' between two rising pulses on 'trigger', it sets counter event output high.
    Is this possible? Reading through the manual of M series PCI-62xx devices, the index pulse loads the counter with a particular value so it seems like you could conceivably set the counter to the terminal count if you wanted. My only real problem is whether DAQmx Export Signal Property Node works on all counter tasks or just on edge counting tasks. 
    Thanks in advance for your help. If this isn't possible, I can reply with more details on the problem this is supposed to solve so that you can help me figure out an alternate method.
    Solved!
    Go to Solution.

    There is probably a way to do it, but it it may be easier to use an X-series board for the job.   They support a new counter capability for count reset on a digital edge without needing to be configured in encoder position mode.  I am not sure exactly how that feature's been implemented however, so maybe it won't make things easier after all.
    The plan based on the hoped-for behavior: 
    1. Configure an X-series counter for pulse generation based on "ticks" of your clock channel.
    2. Set both initial delay and low time to the critical # of ticks.
    3. Configure for count reset on a digital edge (if possible in pulse generation mode)
    4. Configure the count reset value to be the critical # (or possibly 1 less, if possible in pulse generation mode)
    5. If you want the output to remain high indefinitely, configure the counter task to use its own output as a
    pause trigger, and pause while high.
    The way pulse generation works is to preload a # of "low time" ticks into the count register.  Then every source edge will decrement the count.  When the count reaches terminal count (0), the counter's output is toggled (or can be configured to pulse).  The register is then loaded with the # of "high time" ticks and the process continues.
    You would be perpetually interrupting the count-down process as long as you got your triggers in time.  The count would keep getting reset to the # of low counts, keep decrementing toward 0 without reaching it, and so on.  If ever you did reach 0, the output state would toggle high, then the high state would prevent subsequent clock signals from decrementing the count.
    You can conceivably do a similar thing with a 6601, but I'm pretty sure you'd need 2 counters working together to get it working.
    -Kevin P

Maybe you are looking for

  • SAP MRS -  Multi Resource Planning Tool

    Hi All, I am looking for 'introductionary' information on the SAP MRS tool. There is a thread already on this tool but it does not give basic data about functionality and implementaion etc.. (below) MRS (Multi Resource Scheduling) Does anyone have a

  • Folio update bug in the branded viewer v23

    Hi, We have a 6-page flatten folio (each page is a separate article) that we updated. If folio was previously downloaded in the viewer and then updated (without archiving of the old one), page 5 (5th article) remains old page (same thing happened on

  • Wlw-runtime-config.xml & two managed servers

    I have a problem with WSDL generation and WebLogic workshop in a cluster. I'm using a wlw-runtime-config.xml file to ensure that my web service generates the correct url for it's endpoint. The problem I have is that I have two managed servers on one

  • Apps installed but can't find them!

    I have skygo and BBC I player apps on my iPad but overnight I cannot find the icons for the apps when I try to reinstall the apps it says I already have them installed but I can't find them to delete to then reinstall! Help me please where have they

  • Love the new iPhoto!

    anyone reading these forums wondering if the upgrade is worth it, wonder no more. the events feature is really cool, I cant see how i lived without it. the interface has much more snap to it and it hasn't had one slow down yet.