home *** CD-ROM | disk | FTP | other *** search
- /*
- Listing 18.30 Unsqz_p()
- Author: Joe Booth
- Excerpted from "Clipper 5: A Developer's Guide"
- Copyright (c) 1991 M&T Books
- 501 Galveston Drive
- Redwood City, CA 94063-4728
- (415) 366-3600
- */
-
-
- function unsqz_p(cBinary)
- LOCAL cPhone,nHold,cHold
- nHold :=Bin2l(cBinary)
- cHold :=Alltrim(str(nhold,11))
- cHold :=if(len(cHold)<>10,"0"+cHold,cHold)
- cPhone :="("+substr(cHold,2,1)+substr(cHold,1,1)+;
- substr(cHold,3,1)+") "+substr(cHold,4,3)+;
- "-"+substr(cHold,7,4)
- return cPhone
-
- // end of file CHP1830.PRG
-