Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Question on TEXT ENDTEXT use
Message
 
 
À
28/01/2012 21:38:13
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Versions des environnements
Visual FoxPro:
VFP 9 SP1
Divers
Thread ID:
01533979
Message ID:
01533994
Vues:
39
Thank you. You are right.

>The word PRETEXT is misleading, as far as I understand your question PRETEXT=15 will give you exactly what you want.
>
>>I will try it although I don't understand how it will change the result. I thought PRETEXT "manages" only what is "before" each line. But maybe I am missing something. Thank you.
>>
>>>Use pretext 15 instead of 7.
>>>
>>>>Hi,
>>>>
>>>>I am trying to change assigning a literal string to a variable to using TEXT ENDTEXT (literal can sometime exceed the allowed length). But I don't know how to use the TEXT ENDTEXT so that the resulting variable is one string without spaces. Here is an example:
>>>>
>>>>Literal (exactly how it is in my code with all the semicolons):
>>>>
>>>>cSqlCommand = "select mytable.field1, mytable.field2 from mytable " + ;
>>>>" left join mytable2 on mytable.pk = mytable2.pk " + ;
>>>>" where " + cSomeFilterExpr + " order by field1, field2 "
>>>>
>>>>
>>>>My attempt at TEXT ENDTEXT:
>>>>
>>>>TEXT TO cSqlCommand TEXTMERGE NOSHOW PRETEXT 7
>>>>       select mytable.field1, mytable.field2 from mytable
>>>>       left join mytable2 on mytable.pk = mytable2.pk 
>>>>       where  <<cSomeFilterExpr>> order by field1, field2
>>>>ENDTEXT
>>>>
>>>>
>>>>The problem (as I see it) is that in the bottom case (TEXT TO ENDTEXT) the variable cSqlCommand (in Messagebox()) looks just like it is on the screen. And it should be all in one string. What am I missing? TIA.
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform