For/Next loop example (Basic syntax)


 — —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  — —
Sup­port machine trans­la­tion: http://amzn.to/1Z7d5oc
 — —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  — —















Crys­tal Reports Online Help
For/Next loop example (Basic syn­tax)
Here is a more detailed example of Crys­tal Reports’ string pro­cessing cap­ab­il­it­ies. The Caesar cipher is a sim­ple code that is tra­di­tion­ally cred­ited to Juli­us Caesar. In this code, each let­ter of a word is replaced by a let­ter five char­ac­ters fur­ther in the alpha­bet. For example, ““Jaws”” becomes ““Ofbx””. Notice that ““w”” is replaced by ““b””. Since there are not 5 char­ac­ters after ““w”” in the alpha­bet, it starts again from the begin­ning.
Here is a for­mu­la that imple­ments apply­ing the Caesar cipher to the field {Customer.Customer Name} in the Xtreme data­base:
Rem The Caesar cipher
Dim inString The input string to encrypt
inString = {Customer.Customer Name}
Dim shift
shift = 5
for­mu­la = “”””
Dim i
For i = 1 To Len(inString)
Dim inC, outC
inC = Mid(inString, i, 1)
Dim isChar, isU­Case­Char
isChar = LCase(inC) In ““a”” To ““z””
isU­Case­Char = isChar And (UCase (inC) = inC)
inC = LCase(inC)
If isChar Then
Dim off­set
off­set = (Asc(inC) + shift — Asc(““a””)) Mod _
(Asc(““z””) — Asc(““a””) + 1)
outC = Chr(offset + Asc(““a””))
If isU­Case­Char Then outC = UCase(outC)
Else
outC = inC
End If
for­mu­la = for­mu­la & outC
Next iIn the above example, there is a mul­ti-line If state­ment nes­ted with­in the state­ments block of the For/Next loop. This If state­ment is respons­ible for the pre­cise details of shift­ing a single char­ac­ter. For example, let­ters are treated dif­fer­ently from punc­tu­ation and spaces. In par­tic­u­lar, punc­tu­ation and spaces are not encoded. Con­trol struc­tures can be nes­ted with­in oth­er con­trol struc­tures and mul­tiple state­ments can be included in the state­ment block of a con­trol struc­ture.
 — —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  —  — –

Pre­vi­ous page Next page
SAP Busi­nessOb­jects
http://www.sap.com/sapbusinessobjects/
Sup­port ser­vices
http://service.sap.com/bosap-support/
Pro­duct Doc­u­ment­a­tion on the Web
http://help.sap.com/


 — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — – — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — – — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — –
Appoġġ ta traduzz­joni awto­matika: http://amzn.to/1Z7d5oc
 — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — – — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — – — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — –

Rap­porti Crys­tal Online Għa­jnuna
Per / Li jmiss eżem­pju loop (sin­tassi Bażiku)
Hawn hu eżem­pju aktar dettal­jata tal-kapaċitaji­et ta pproċes­sar spag Rap­porti Crys­tal “”. Il cipher Caesar huwa kodiċi sem­pliċi li huwa tradizz­jon­al­ment kkred­it­at lill Juli­us Caesar. F’dan il-kodiċi, kull ittra ta kel­ma hija sostit­wita minn ittra ħames kar­at­tri aktar fl-alfa­bett. Per eżem­pju, ““xedaq”” isir ““Ofbx””. Avviż li ““w”” huwa mib­dul b ’ ““b””. Peress li ma jkunx hemm 5 kar­at­tri wara ““w”” fl-alfa­bett, jib­da mill-ġdid mill-bidu.
Hawn­hekk huwa for­mu­la li tim­pli­menta app­likazz­joni tal-cipher Caesar għall-qasam {Customer.Customer Isem} fid-data­base Xtreme:
Rem Il Caesar cipher
inString DIM ““L sek­wen­za input għall-kriptaġġ
inString = {Customer.Customer Isem}
bid­la dIM
shift = 5
For­mu­la = “”””
i dIM
Għal i = 1 Biex Len (inString)
Dim inc, outC
INC = Nofs it (inString, i, 1)
Dim isChar, isU­Case­Char
isChar = LCase (inc) Fi ““a”” u ““z””
isU­Case­Char = isChar U (UCase (inc) = inc)
INC = LCase (inc)
Jekk isChar Imbagħad
dim off­set
off­set = (ASC (inc) + shift — ASC ( ““a””)) Mod _
(ASC ( ““z””) — ASC ( ““a””) + 1)
outC = Chr (off­set + ASC ( ““a””))
Jekk isU­Case­Char Imbagħad outC = UCase (outC)
Else
outC = inc
Tmiem Jekk
for­mu­la = for­mu­la & outC
Li jmiss fFil-eżem­pju hawn fuq, hemm mul­ti-lin­ja Jekk dikjarazz­joni nes­ted fi ħdan id-dikjarazz­jon­iji­et blokk tal-Għat / loop jmiss. Din id-dikjarazz­joni Jekk huwa responsab­bli għad-dettalji preċiżi tal ċaqliq kar­at­tru wieħed. Per eżem­pju, l-ittri huma ttrat­tati b’mod dif­fer­enti mill-punteġġ­jat­ura u spazji. B’mod partikolari, punteġġ­jat­ura u spazji ma jkunux kodi­fikati. istrut­turi ta kon­troll tista’ tiġi nes­ted fi ħdan strut­turi oħra ta kon­troll u dikjarazz­jon­iji­et mul­ti­pli jist­għu jiġu inklużi fil-blokk dikjarazz­joni ta’ strut­tura ta kon­troll.
 — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — – — —  —  —  —  —  —  —  — —

paġna ta qabel paġna li jmiss
SAP Busi­nessOb­jects
http://www.sap.com/sapbusinessobjects/
ser­vizzi ta appoġġ
http://service.sap.com/bosap-support/
Dok­u­mentazz­joni pro­dott fuq il-Web
http://help.sap.com/
 


 — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — – — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — – — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — –
Onder­steun­ing masji­en ver­tal­ing: http://amzn.to/1Z7d5oc
 — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — – — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — – — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — –

Crys­tal Reports Online Hulp
Vir / Vol­gende lus voor­beeld (Basiese sin­tak­s­is)
Hier is n meer gede­tailleer­de voor­beeld van string ver­werking ver­moëns Crys­tal Reports. Die keiser cipher is n een­voud­i­ge kode wat tradision­eel toegeskryf aan Juli­us Caesar. In hierdie kode, is elke let­ter van n woord ver­vang deur n brief vyf karak­ters ver­der in die alfa­bet. Byvoor­beeld, ““Jaws”” raak ““Ofbx””. Let daarop dat ““w”” ver­vang deur ““b””. Aangesi­en daar nie 5 karak­ters na ““w”” in die alfa­bet, dit begin weer van die begin af.
Hier is n for­mule wat imple­men­te die toe­p­assing van die keiser cipher die veld {Customer.Customer Naam} in die Xtreme data­bas­is:
Rem Die keiser cipher
Dowwe inString Die insette tou te enkripteer
inString = {Customer.Customer Naam}
dowwe ver­skuiwing
skuif = 5
for­mule = “”””
dowwe i
Vir i = 1 Om Len (inString)
Dowwe INC, outC
inc = Mid (inString, ek, 1)
Dowwe isChar, isU­Case­Char
isChar = LCase (incl) In ““A”” tot ““Z””
isU­Case­Char = isChar en (UCase (incl) = INC)
inc = LCase (incl)
As isChar Toe
dowwe ver­rek­en
gen­eut­ral­iseer = (ASC (incl) + shift — ASC ( ““a””)) Mod _
(ASC ( ““z””) — ASC ( ““a””) + 1)
outC = Chr (ver­rek­en + ASC ( ““a””))
As isU­Case­Char Dan outC = UCase (outC)
anders
outC = INC
eindig As
for­mule = for­mule & outC
Vol­gende Iin die bogen­oem­de voor­beeld, daar is n mul­ti-line As stelling gen­este bin­ne die state te sluit van die Vir / Vol­gende lus. Dit As stelling is ver­ant­woor­delik vir die pres­iese beson­der­hede van die ver­skuiwing van n enkele karak­ter. Byvoor­beeld, is briewe anders behan­del van punk­tu­asie en spasies. In die beson­der, is punk­tu­asie en spasies nie geïnkripteer. Beheer­struk­ture kan ber­us op n ander beheer­struk­ture en ver­skeie state kan ingesluit word in die verklar­ing blok van n beheer­struk­tuur.
 — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — – — —  —  —  —  —  —  —  — —

Vori­ge Vol­gende
SAP Busi­ness
http://www.sap.com/sapbusinessobjects/
onder­steun­ings­di­en­ste
http://service.sap.com/bosap-support/
Produk dok­u­mentas­ie op die web
http://help.sap.com/
 


 — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — – — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — – — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — –
Mbështetje mak­inë përk­thim: http://amzn.to/1Z7d5oc
 — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — – — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — – — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — –

Crys­tal Reports Online Ndih­më
Për shem­bu­ll / Next lak (sin­tak­sës Basic)
Këtu është një shem­bu­ll më i detajuar i aftës­ive të për­pun­im­it string Crys­tal Reports. Cez­ari shi­fër është një kod i thjeshtë që është kred­it­u­ar tradi­cion­al­isht të Juli­us Caesar. Në këtë kod, çdo letër e një fjalë është zëvendësuar me një letër pesë karaktere të mëtejsh­me në alfa­bet­in. Për shem­bu­ll, ““Jaws”” bëhet ““Ofbx””. Vini re se ““w”” zëvendëso­het me ““b””. Që nuk ka 5 karaktere pas ““w”” në alfa­bet­in, ajo fil­lon për­sëri nga fil­limi.
Këtu është një for­mulë që zbat­on aplikuar shi­fër Cez­ar­it në fushë {Customer.Customer Emri} në bazën e të dhënave Xtreme:
Rem Cez­ari shi­fër
inString Dim Var­gu input të encrypt
inString = {Customer.Customer Emri}
ndry­shim dim
ndry­shim = 5
for­mu­la = “”””
i dim
Për i = 1 To Len (inString)
Dim INC, outC
INC = Mid (inString, i, 1)
Dim isChar, isU­Case­Char
isChar = LCase (Inc) Në ““a”” deri ““z””
isU­Case­Char = isChar Dhe (UCase (Inc) = Inc)
INC = LCase (Inc)
Nëse isChar Pas­taj
dim kom­pen­suar
kom­pen­suar = (ASC (Inc) + shift — ASC ( ““a””)) Mod _
(Asc ( ““z””) — Asc ( ““a””) + 1)
outC = Chr (off­set + ASC ( ““a””))
Nëse isU­Case­Char Pas­taj outC = UCase (outC)
tjetër
outC = inc
End If
for­mu­la = for­mu­la & outC
Next iin shem­bu­llin e mësipërm, nuk është një mul­ti-line Nëse deklarata mbi­vendos­ur brenda deklaratave të bllok­uar nga Per / lak tjetër. Kjo deklar­atë Nëse është për­gjegjëse për deta­jet e sak­ta të zhvendos­ur një karak­ter të vetëm. Për shem­bu­ll, letrat janë tra­jtu­ar ndry­she nga shen­jat e pikësim­it dhe hapësira. Në veçanti, shen­jat e pikësim­it dhe hapësir­at nuk janë të koduara. struk­tur­at e kon­trol­lit mund të mbi­vendos­ur brenda struk­turave të tjera të kon­trol­lit dhe deklara­tat e shumta mund të përf­shi­hen në bllok­un deklar­atë e një struk­ture të kon­trol­lit.
 — —  —  —  —  —  —  —  —  —  —  —  —  —  —  — – — —  —  —  —  —  —  —  — —