Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Excel, check to see if a range name exists?
Message
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Excel, check to see if a range name exists?
Divers
Thread ID:
00926603
Message ID:
00926603
Vues:
100
I am trying to find out if a range name exists before creating one in excel. I can get
a list of all range names with step 2. However, if I first create a new range name oRange,
as in step 1, the process in step 2 will not find this name. and after I run step 2, the new
range name oRange is gone. how can I check to see if a range name has already been used.
Thanks
Steve

** step 1
oEx = GETOBJECT(,'excel.application')
oRange = "asdf"
ThisNewName = orange
oRange = oEx.Range("a1")
WAIT WINDOW oRange.value && shows .7036

*** step 2
FOR i = 1 TO o.Names.Count
thisOne = ALLTRIM(LOWER(oEx.Names[i].name ))
IF thisNewName$thisOne
? oEx.Names[i].name
endif
ENDFOR
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform