Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Why VFP Ole Db does not like ampersand sign.
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Versions des environnements
Visual FoxPro:
VFP 9 SP1
Divers
Thread ID:
01291957
Message ID:
01291958
Vues:
35
This message has been marked as the solution to the initial question of the thread.
Dmitry,

No this is probably not something weird, it is probably that the & is a reserved character in VFP that does macro expansion even whne it is inside of quotes. So how do you deal with it? You break up your strings into pieces a=that keep the & from ever being next to another character as in;
lcVar = STRTRAN(lcMyOtherVar, "&" + "amp;", "&" + "new;")
This way you never run into a problem becasue there is variable named amp somewhere and VFP tries to macro the varaiable when it sees "&".

As an example try running this code;
amp = "My best work"
? "&"
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform