Setting FixedValue Content Equal to the Value of an Input Parameter


/ Published in: C#
Save to your folder(s)

content transformation script to set the content element equal to the value of an input parameter


Copy this code and paste it in your HTML
  1. using System;
  2. 03.using VisualWebRipper.Internal.SimpleHtmlParser;
  3. 04.using VisualWebRipper;
  4. 05.public class Script
  5. 06.{
  6. 07. public static string TransformContent(WrContentTransformationArguments args)
  7. 08. {
  8. 09. try
  9. 10. {
  10. 11. return args.InputParameters["par1"];
  11. 12. }
  12. 13. catch(Exception exp)
  13. 14. {
  14. 15. args.WriteDebug(exp.Message);
  15. 16. return "Custom script error";
  16. 17. }
  17. 18. }
  18. 19.}

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.