home *** CD-ROM | disk | FTP | other *** search
/ Chip 2003 December / Chip_2003-12_cd2.bin / oo / download / f_0019 / sbasic.jar / text / sbasic / common / 03120308.xml < prev    next >
Extensible Markup Language  |  2003-01-16  |  5KB  |  56 lines

  1. <?xml version="1.0" encoding="utf-8"?>
  2. <html><head><title>P┼Ö├¡kaz RSet [Runtime]</title><meta name="filename" content="text/sbasic/common/03120308"/><meta name="language" content="en-US"/><help:css-file-link xmlns:help="http://openoffice.org/2000/help"/><!--The CSS style header method for setting styles--><style type="text/css">
  3.  
  4.         p.P1{
  5.                 }
  6.         p.P2{
  7.                 }
  8.         span.T1{
  9.                 font-weight:bold;}
  10.         </style></head><body>
  11.   
  12.   
  13.   <help:to-be-embedded Eid="rset" xmlns:help="http://openoffice.org/2000/help">
  14.   <p class="Head1"><help:link Id="66602">P┼Ö├¡kaz RSet [Runtime]</help:link></p>
  15.   <p class="Paragraph">Zarovn├í text typu String vpravo v r├ímci prom─¢nn├⌐ typu String nebo zkop├¡ruje u┼╛ivatelem definovan├╜ typ prom─¢nn├⌐ do jin├⌐.</p>
  16.   </help:to-be-embedded>
  17.   <p class="Paragraph"><span class="T1">Syntaxe</span>:</p>
  18.   <p class="Paragraph">RSet Text typu String = Text nebo RSet Prom─¢nn├í1 = Prom─¢nn├í2<help:key-word value="RSet" tag="kw66602_1" xmlns:help="http://openoffice.org/2000/help"/></p>
  19.   <p class="Paragraph"><span class="T1">Parametr</span>:</p>
  20.   <p class="Paragraph">Text: Jak├íkoli prom─¢nn├í typu String.</p>
  21.   <p class="Paragraph">Text: Text typu String, kter├╜ m├í b├╜t v prom─¢nn├⌐ typu String zarovn├ín vpravo.</p>
  22.   <p class="Paragraph">Prom─¢nn├í 1: U┼╛ivatelem definovan├í prom─¢nn├í, kter├í je c├¡lovou hodnotou zkop├¡rovan├⌐ prom─¢nn├⌐.</p>
  23.   <p class="Paragraph">Prom─¢nn├í 2: U┼╛ivatelem definovan├í prom─¢nn├í, kter├í m├í b├╜t zkop├¡rov├ína do jin├⌐ prom─¢nn├⌐.</p>
  24.   <p class="Paragraph">Je-li text typu String krat┼í├¡ ne┼╛ prom─¢nn├í typu String, zarovn├í p┼Ö├¡kaz <span class="T1">RSet</span> text typu String v prom─¢nn├⌐ typu String vpravo. V┼íechny zb├╜vaj├¡c├¡ znaky v prom─¢nn├⌐ typu String budou nahrazeny mezerami. Je-li text typu String del┼í├¡ ne┼╛ prom─¢nn├í typu String, budou znaky p┼Öesahuj├¡c├¡ d├⌐lku prom─¢nn├⌐ o┼Ö├¡znuty. Zarovn├íny vpravo budou pouze zb├╜vaj├¡c├¡ znaky v prom─¢nn├⌐ typu String.</p>
  25.   <p class="Paragraph"><span class="T1">P┼Ö├¡kaz RSet</span> lze pou┼╛├¡t tak├⌐ k p┼Öi┼Öazen├¡ prom─¢nn├╜ch jednoho typu definovan├⌐ho u┼╛ivatelem do jin├⌐ho.</p>
  26.   <p class="Paragraph">V p┼Ö├¡kladu se p┼Ö├¡kazy <span class="T1">RSet</span> a <span class="T1">LSet</span> pou┼╛├¡vaj├¡ k ├║prav─¢ zarovn├ín├¡ textu typu String vlevo a vpravo.</p>
  27.   <p class="P2">P┼Ö├¡klad:</p>
  28.   <p class="PropText">Sub ExampleRLSet</p>
  29.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>Dim sVar as string</p>
  30.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>Dim sExpr as string</p>
  31.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/></p>
  32.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>sVar = String(40,"*")</p>
  33.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>sExpr = "SBX"</p>
  34.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>REM <text:s text:c="" xmlns:text="http://openoffice.org/2000/text"/>Right-align "SBX" in a 40-character string</p>
  35.   <p class="PropText">REM <text:s text:c="" xmlns:text="http://openoffice.org/2000/text"/>Replace asterisks with spaces</p>
  36.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>RSet sVar = sExpr</p>
  37.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>Print ">"; sVar; "<"</p>
  38.   <p class="PropText"/>
  39.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>sVar = String(5,"*")</p>
  40.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>sExpr = "123457896"</p>
  41.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>RSet sVar = sExpr</p>
  42.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>Print ">"; sVar; "<"</p>
  43.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/></p>
  44.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>sVar = String(40,"*")</p>
  45.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>sExpr = "SBX"</p>
  46.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>REM Left-align "SBX" in a 40-character string</p>
  47.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>LSet sVar = sExpr</p>
  48.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>Print ">"; sVar; "<"</p>
  49.   <p class="PropText"/>
  50.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>sVar = String(5,"*")</p>
  51.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>sExpr = "123456789"</p>
  52.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>LSet sVar = sExpr</p>
  53.   <p class="PropText"><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/>Print ">"; sVar; "<"<text:tab-stop xmlns:text="http://openoffice.org/2000/text"/><text:tab-stop xmlns:text="http://openoffice.org/2000/text"/></p>
  54.   <p class="PropText">End Sub</p>
  55.  </body></html>
  56.