format

sas date - convert today() into yyyymmdd format..

How do I convert a SAS date such as "30JUL2009"d into YYYYMMDD format (eg 20090730) ?? so for instance: data _null_; format test ?????; test=today(); put test=; run; would give me "test=20090730" in the log.... ...

Oracle - output not coming in right format

Hi All, I have set the below parameters in sqlplus to display my view out put on unix box,However it is displaying one line gap between two records.I don't want that one line gap between two records Ex- set feedback off SET NEWPAGE NONE set HEADING Off set pagesize 0 set linesize 125 SET TRIMSPOOL ON set termout off spool /export/home/4...

Python string Formatting

I have a string of this form s='arbit' string='%s hello world %s hello world %s' %(s,s,s) All the %s in string have the same value (i.e. s). Is there a better way of writing this? (Rather than listing out s three times) ...

How to read the XSD datetime format in PHP ?

Is there a function, class, or extension in PHP that can handle the XSD datetime format? It's a standard XML date & time format, that looks like this: <date>2008-02-28T07:56:35.263</date> I know I can read it with a regular expression, if no solution is given, I'll default to that. Thanks! PS: Solved, look at the answers. ...

PHP IMAP Formatting

I have wrote a simple php script which reads an IMAP email account and displays the body of the most recent mail. There is just one problem, it won't keep the new lines properly. It just puts it all on one line. I use imap_fetchbody($conn, $latest, "1"); to read the body of the email. How do I keep the original formatting with all t...

C# binary constants representation

I am really stumped on this one. In C# there is a hexadecimal constants representation format as below : int a = 0xAF2323F5; is there a binary constants representation format? ...

Why isn't my Perl format working?

All, I'm trying to get the code at the bottom to look like a check. Could you help me troubleshoot? Thanks, Frank format STDOUT = @<<<<<<<<<<<<<<<<<<<<<<<<<<<<< @>>>>>>>>>>>>>>>>>>>>>>>>>>>>> $chkno $chkno $first $last ...

How might I format an alist in common lisp?

I'm beginning to write me some Common Lisp and am just getting the hang of consing things together and formatting them. Let's suppose I have an alist, like this: (defvar *map* '((0 . "zero") (1 . "one") (2 . "two"))) How do I format it like this? 0: zero 1: one 2: two I was thinking something like (format t "~{~{~a: ~a~}~%~}" *map...

Display Multiple Form Submit Buttons Inline Same Line In IE8 In Table

I am trying to display two form submit buttons on the same line inside a table. In IE7 the following code works great, however in IE8 the Delete button drops down to the next line even though I declared the form to display inline. Any suggestions? I created a basic test page here to show the issue: http://ajondeck.net/test/displayinli...

Printing the value of a float to 2 decimal places

I have a float with the value of e.g 57.400002. I use sprintf_s to display the value on my GUI. sprintf_s(xPosition, 19, "%f", xPositionValue); How can I format the float so it displays as 57.40? ...

transfer text to clipboard that is underlined

I have a program that the user enters some data and then it creates a form letter and copys it to there clipboard Some of the users came back and said they would like some parts of the letter to be underlined to help the people they are sending it to read it easier ( headlines etc) I don't know of a way to mark something as underlined ...

Why is the Date format changing?

I have an Excel spreadsheet where there is a date column, and the date is entered in the format of dd/mm/yyyy. When I open this file in My Excel, the Date column converts to date, but in the format of mm/dd/yyyy automatically. i.e., 12/03/2009 4:44:44 (12March) but it takes it as 3rd Dec 09.. Would you please shed some light on the ma...

Android TextView Justify Text

Hey, How do you get the text of a TextView to be Justified (with text flush on the left- and right- hand sides)? I found a possible solution here, but it does not work (even if you change vertical-center to center_vertical, etc). Cheers, Pete ...

Last.fm API - Track Duration

I'm using the Last.fm API and I stuck on something seemingly fairly simple. One of the responses is the duration. Which is returned as: 222000 But how do I format (in PHP) this to look like MIN:SEC 3:42 ...

Audio Conversion C#

What is the best way to convert various audio formats to PCM? For example: mp3, evrc, ogg vox. Is there a library out there that will allow me to implement this relatively easily? EDIT: I guess my initial question wasn't really what I needed. Most of the libs I have found are file converters. What I need is a block converter, wher...

How can I use Unicode characters when I write to Perl's format?

Basically I have a database where I get $lastname, $firstname, $rid, $since, $times and $ip from. Using a Perl script, I format the data to send it via e-mail. Since the $lastname and $firstname can contain special chars (for instance ä, ü, ß, é,...) I first decode the strings. my $fullname = decode("utf8", $lastname) . ', ' . decode("...

Looking for some sample code audio conversion with the iPhone caf=>m4a

Hi Developers, I am struggling with converting a recorded pcm/caf file (recorded via the AudioQueue) to a m4a file. I should be possible somehow with the "AudioConverter.h" but doesn't seem to be easy at all. If you have seen an example or have a code snippet it would be great if you can post it. Thanks for your help Tom ...

How do I set query field formats at vba runtime

I am creating a Crosstab query at runtime with the option of using a summary type of "SUM" or "COUNT". If I set Sum, then I want an output format of "$#,##0.00", and if it is Count, then I want an output format of "#,##0". There are lots of discussion questions setting a tableDef Field property to format output, but there is nothing th...

Prevent round off in String.format("%.2f", doubleValue) in Java

How do I prevent String.format("%.2f", doubleValue); from rounding off (round half up algorithm) instead of just truncating it? e.g. doubleValue = 123.459 after formatting, doubleValue = 123.46 I just want to discard the last digit, 123.45 I know there are other ways to do this, I just want to know if this is possible using the...

Excel data wont re-format or calculate

I have a spreadsheet that was created from a webapp. I save it as an excel wkbk. I close file and go to file and open from my pc. When I try to reformat a column of numbers, nothing happens. (it says the format is 'general' and alignment is 'general & top') it appears as all numbers, left aligned. I have tried to 'unlock' the cells...