Re: Hard Break

2000-10-29 Thread KRM

try something like this:

cfset vRecord = vRecord  Chr(13)  Chr(10)

Keith Meade
www.kmweb.com

- Original Message -
From: "Brian bouldernet" [EMAIL PROTECTED]
To: "CF-Talk" [EMAIL PROTECTED]
Sent: Monday, October 30, 2000 2:10 AM
Subject: Hard Break


: Quick Question:
: Anyone know how to enter a hard break to a text file using CF functions
or
: variable. I have a comma delimeted output and need to create a hard
break
: for more than one record to export.
: Code:
:
: cfset rightnowtime = #Timeformat(Now(), "HHmmss")#
: CFSET thisListHeadings=ArrayToList(ArrayHeadings, ",")
: CFSET thisList=ArrayToList(ArrayData, ",")
: cfset rightnowdate = #Dateformat(Now(), "mmdd")#
: CFFILE ACTION="WRITE" FILE="D:\out\#rightnowdate##rightnowtime#.txt"
: OUTPUT="#thisList#"
:
: ---
-
: Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
: Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists or
send a message with 'unsubscribe' in the body to
[EMAIL PROTECTED]


Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists or send a message 
with 'unsubscribe' in the body to [EMAIL PROTECTED]



Re: Refresh Question?

2000-09-29 Thread KRM

Here's a cute way to disable a submit button after it's been pressed:

- start of code ---
script language="JavaScript"
 function doSubmit(btn) {
  if (btn.value != "Please wait...")
  btn.form.submit();
  btn.value = "Please wait...";
  }
/script

input type=submit name=btnSubmit
value="Save My Stuff"
  onClick="doSubmit(this)"
- end of code ---

It depends on client JavaScript, so it's not a total solution.  You'd
still want to do some sort of duplicate transaction checking.  Still,
it's an elegant technique that keeps the user informed.

Keith Meade
www.kmweb.com

- Original Message -
From: "HappyToad.com" [EMAIL PROTECTED]
To: "CF-Talk" [EMAIL PROTECTED]
Sent: Friday, September 29, 2000 11:08 AM
Subject: Refresh Question?


: How can I stop multiple records being added to the database when a user
: clicks refresh on a form action page?
:
: Rich
:
: ---
---
: Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
: To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=listsbody=lists/cf_talk
or send a message to [EMAIL PROTECTED] with 'unsubscribe'
in the body.

--
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=listsbody=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.



Re: Autonumber?

2000-09-28 Thread KRM

How about this?

cfset Unique_ID = DateFormat(Now(),"yymmdd")  TimeFormat(Now(),"hhmm")
 "-"  Right(GetTickCount(),5)

It's not *totally* bulletproof.  If two processes run the code at the
exact same millisecond, you'll have a duplicate ID.  I would implement
this line plus the
database INSERT within a CFLOCK.  That would pretty much kill any
chance
of a dup.  On a very high volume site, I would use the database
facilities that others have described.

Keith Meade
www.kmweb.com

- Original Message -
From: "HappyToad.com" [EMAIL PROTECTED]
To: "CF-Talk" [EMAIL PROTECTED]
Sent: Thursday, September 28, 2000 7:12 AM
Subject: RE: Autonumber?


: I am getting the following error when I tried to use the code you sent
me.



--
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=listsbody=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.