Advertisement
Guest User

Untitled

a guest
Nov 28th, 2014
169
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.35 KB | None | 0 0
  1. Dynamic form: xfa.host.messageBox("Warning text", "Window title", type);
  2.  
  3. 1 var text = xfa.resolveNode('$data..TextField1').value;
  4. 2 var HelloDlg =
  5. 3 {
  6. 4 initialize: function (dialog)
  7. 5 {
  8. 6 var todayDate = dialog.store()["date"];
  9. 7 todayDate = "Date: " + util.printd("mmmm dd, yyyy", new Date());
  10. 8 dialog.load({ "date": todayDate });
  11. 9 },
  12. 10 description:
  13. 11 {
  14. 12 elements:
  15. 13 [
  16. 14 {
  17. 15 type: "view",
  18. 16 elements:
  19. 17 [
  20. 18 {
  21. 19 item_id: "str1",
  22. 20 name: "Hello, this is a demo box.",
  23. 21 type: "static_text",
  24. 22 font: "dialog",
  25. 23 bold: true,
  26. 24 alignment: "align_center",
  27. 25 char_width: 30,
  28. 26 height: 20,
  29. 27 },
  30. 28 {
  31. 29 type: "gap",
  32. 30 },
  33. 31 {
  34. 32 type: "view",
  35. 33 align_children: "align_row",
  36. 34 elements:
  37. 35 [
  38. 36 {
  39. 37 item_id: "str2",
  40. 38 name: "Your text:",
  41. 39 type: "static_text",
  42. 40 },
  43. 41 {
  44. 42 item_id: "str3",
  45. 43 name: text,
  46. 44 type: "static_text",
  47. 45 font: "dialog",
  48. 46 bold: true,
  49. 47 }
  50. 48 ]
  51. 49 },
  52. 50 {
  53. 51 item_id: "date",
  54. 52 name: "Date: ",
  55. 53 type: "static_text",
  56. 54 char_width: 25,
  57. 55 }
  58. 56 ]
  59. 57 },
  60. 58 {
  61. 59 type: "ok",
  62. 60 ok_name: "Ok!",
  63. 61 alignment: "align_right",
  64. 62 }
  65. 63 ]
  66. 64 }
  67. 65 };
  68. 66 app.execDialog(HelloDlg);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement