Script that simply returns the current date


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

Script that simply returns the current date


Copy this code and paste it in your HTML
  1. using System;
  2. using VisualWebRipper.Internal.SimpleHtmlParser;
  3. using VisualWebRipper;
  4. public class Script
  5. {
  6. //See help for a definition of WrInputTransformationArguments.
  7. public static string TransformInput(WrInputTransformationArguments args)
  8. {
  9. try
  10. {
  11. return DateTime.Now.ToString("dd/MM/yyyy");
  12. }
  13. catch(Exception exp)
  14. {
  15. //Place error handling here
  16. args.WriteDebug(exp.Message);
  17. return "Custom script error";
  18. }
  19. }
  20. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.