Creating a custom cflock in cfscript.

Ask a Question related to Coldfusion - Advanced Techniques, Design and Development.

  1. #1

    Default Creating a custom cflock in cfscript.

    I have been thinking on how to do this for a few days now. I am building a few
    pages in cfscript, where the ENTIRE page is cfscript, no cftags, the only area
    I allow cftags are user-defined functions (methods).

    And the problem is locking, when reading and writing to sessions and
    application variables. I have not found a way to do this without escaping the
    script from within the cfscript block. Lets say we set like 10 application
    variables, and we need to surround it with a cflock in cfscript, how can I
    possibly do this without closing the cfscript block? The reason I don't want to
    close it is becuase I am using try and catch within it, and closing it wouldn't
    make it work correctly.

    So what I am looking for is something like a custom cflock like:

    <cfscript>
    variables.cflock()
    {
    code...
    }
    </cfscript>

    Or something liek this, as long as I can do it without closing the cfscript
    block or putting the entire lock code into a component or udf.

    Any ideas would be appreciated here.

    superbullet Guest

  2. Similar Questions and Discussions

    1. <cfscript> autocaps problem </cfscript> - betcha can't fix this!
      First, I'll tell you up front that I am clueless when it comes to cfscript. So I apologize if this question is off topic. I have a nice little...
    2. Creating Custom Line Styles
      How can I create a basic line style of my own (or a custom one). It's quite particular what I want. I'm doing spome CAD illustrations and I need...
    3. Creating custom classes
      Hi all, I have a problem where I am creating objects in a loop. I have the problem that when setting instance properties, the properties of the...
    4. Creating a Custom Cursor
      I used photoshop to create a custom black and white cursor. It is 16x16 grayscale. It's saved as a bitmap. I guess that makes it 8 bit instead of 1...
    5. Creating a custom scrollbar? I got nothing.
      Hello everybody, I did a little research on this forum and took a peek at the director-online.com tutorial and still have been unable to find an...
  3. #2

    Default Re: Creating a custom cflock in cfscript.

    Does anybody have any ideas?
    superbullet Guest

  4. #3

    Default Re: Creating a custom cflock in cfscript.

    I would also like to find out.
    I also prefer cfscript for many things, but cflock and cftransaction are two reasons i use CFML in a component still.
    jorgeloyo Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139