[paramétrage] adressage absolu par défaut

ogle

XLDnaute Nouveau
Bonjour le forum,

Une petite question. Lorsqu'on écrit une formule faisant référence à un fichier extérieur, excel fait par défaut un adressage absolu des cellules (i.e met des $). Savez-vous comment je peux modifier ce paramétrage par défaut ? Je ne trouve rien dans les options.

Merci à vous,
Og
 

Tibo

XLDnaute Barbatruc
Re : [paramétrage] adressage absolu par défaut

Bonsoir,

Je ne sais pas s'il est possible de paramétrer ce point en particulier.

Sinon, dès que tu tapes (ou sélectionnes) ta référence aux cellules d'un autre fichier, tapes aussitôt sur F4 (1 ou plusieurs fois) pour faire varier le relatif / absolu sur la ligne ou la colonne.

@+
 

Staple1600

XLDnaute Barbatruc
Re : [paramétrage] adressage absolu par défaut

Bonjour à tous

Voici deux petits macros bien utiles que j'avais posté dans d'autres fils

(La macro de départ venant du site de Microsoft)

Code:
[FONT=Courier New][COLOR=darkblue]Sub[/COLOR] Convertir_F_REF_ABS()
[COLOR=darkblue]Dim[/COLOR] Mycell [COLOR=darkblue]As[/COLOR] Range
[COLOR=darkblue]For[/COLOR] [COLOR=darkblue]Each[/COLOR] Mycell [COLOR=darkblue]In[/COLOR] ActiveSheet.UsedRange
  [COLOR=darkblue]If[/COLOR] Len(Mycell.Formula) > 0 [COLOR=darkblue]Then[/COLOR]
    [COLOR=green]'Stores cell's formula as variable[/COLOR]
    MyFormula = Mycell.Formula
    [COLOR=green]'Converts formula to absolute reference style[/COLOR]
    NewFormula = Application.ConvertFormula _
        (My[COLOR=darkblue]For[/COLOR]mula, xlA1, xlA1, xlAbsolute)
    [COLOR=green]'Replaces old formula with new absolute formula[/COLOR]
    Mycell.Formula = NewFormula
    [COLOR=darkblue]End[/COLOR] [COLOR=darkblue]If[/COLOR]
[COLOR=darkblue]Next[/COLOR]
[COLOR=darkblue]End[/COLOR] [COLOR=darkblue]Sub[/COLOR]
[COLOR=darkblue]Sub[/COLOR] Convertir_F_ABS_REL()
[COLOR=darkblue]Dim[/COLOR] Mycell [COLOR=darkblue]As[/COLOR] Range
[COLOR=darkblue]Dim[/COLOR] Plage [COLOR=darkblue]As[/COLOR] Range
[COLOR=darkblue]Set[/COLOR] Plage = Application.InputBox(Prompt:= _
"Veuillez sélectionner les cellules à convertir", _
Title:="Convertion en références relatives", Type:=8)
For [COLOR=darkblue]Each[/COLOR] Mycell [COLOR=darkblue]In[/COLOR] Plage
  [COLOR=darkblue]If[/COLOR] Len(Mycell.Formula) > 0 [COLOR=darkblue]Then[/COLOR]
        MyFormula = Mycell.Formula
        NewFormula = Application.ConvertFormula _
            (MyFormula, xlA1, xlA1, xlRelative)
        Mycell.Formula = NewFormula
    [COLOR=darkblue]End[/COLOR] [COLOR=darkblue]If[/COLOR]
[COLOR=darkblue]Next[/COLOR]
[COLOR=darkblue]End[/COLOR] Sub[/FONT]
 

Discussions similaires

Statistiques des forums

Discussions
312 415
Messages
2 088 237
Membres
103 779
dernier inscrit
FrancoisB2