TooFatBoy
XLDnaute Barbatruc
Certes, mais rassure-moi : j'ai bien compris ce que tu as dit en #63 ?Maudite boisson!
C'est bien comme ça que ça fonctionne ???
Certes, mais rassure-moi : j'ai bien compris ce que tu as dit en #63 ?Maudite boisson!
Tout à fait !Certes, mais rassure-moi : j'ai bien compris ce que tu as dit en #63 ?
C'est bien comme ça que ça fonctionne ???
Waouh ! J'adore le Gribouille_1 !!!Dans la série: Trop de confinement dénature mon Excel
Mais au moins, si c'est futile, c'est joli, non ?
Ben normalement si. Pourquoi ? Ca ne marche pas ?n'y aurait-il pas moyen d'éviter ces répétitions en confiant ce bout-là à une autre macro
qu'il me suffirait d'appeler?
J'ai essayé, mais sans succès!Ben normalement si. Pourquoi ? Ca ne marche pas ?
Tu as peut-être oublié de déclarer x() en variable globale.J'ai essayé, mais sans succès!
Dim cel As Range
Dim ici As Range
Dim n As Long
Dim c As Long
Dim x() As Variant
Sub Départ()
Set ici = Selection
n = ici.Cells.Count
c = Sqr(n)
ReDim x(1 To n)
For Each cel In ici
i = i + 1
x(i) = cel.Interior.ColorIndex
Next cel
End Sub
Sub Identité()
' Hahaha! Une macro qui ne fait rien.
Application.ScreenUpdating = False
End Sub
Sub R_90()
Application.ScreenUpdating = False
Départ
For i = c To 1 Step -1
For j = 1 To c
v = i + (j - 1) * c
k = k + 1
ici.Cells(k).Interior.ColorIndex = x(v)
Next j
Next i
End Sub
Merci, c'est en plein ça. Un nouveau Départ! . Je songe sérieusement à arrêter de picoler!Tu as peut-être oublié de déclarer x() en variable globale.
Pour info, chez moi ça sembler fonctionner sans problème.
VB:Dim cel As Range Dim ici As Range Dim n As Long Dim c As Long Dim x() As Variant Sub Départ() Set ici = Selection n = ici.Cells.Count c = Sqr(n) ReDim x(1 To n) For Each cel In ici i = i + 1 x(i) = cel.Interior.ColorIndex Next cel End Sub Sub Identité() ' Hahaha! Une macro qui ne fait rien. Application.ScreenUpdating = False End Sub Sub R_90() Application.ScreenUpdating = False Départ For i = c To 1 Step -1 For j = 1 To c v = i + (j - 1) * c k = k + 1 ici.Cells(k).Interior.ColorIndex = x(v) Next j Next i End Sub
Ce n'est malheureusement pas de moi.Et en passant, ton "Il y a 10 sortes de personnes : celles qui comprennent le binaire,
celles qui ne le comprennent pas." a fait un tabac sur Facebook!
Sub lime()
Application.ScreenUpdating = False
Grille
Mandelbrot
ActiveWindow.Zoom = 35
Application.ScreenUpdating = True
End Sub
Private Sub Grille()
Range("A1:OF396").ColumnWidth = 0.2
Range("A1:OF396").RowHeight = 2
End Sub
Private Sub Mandelbrot()
D = 99
For x = 1 To 4 * D
For y = 1 To 4 * D
p = 0: q = 0
For j = 1 To 98
c = 2 * p * q
p = p ^ 2 - q ^ 2 - 2 + (x - 1) / D
q = c + 2 + (1 - y) / D
If p ^ 2 + q ^ 2 >= 4 Then Exit For
Next j
j = -j * (j < D)
Cells(y, x).Interior.Color = Rnd(-j) * 1000000# * j / D
Next y, x
'crédits: Engine Toaster - septembre 2017
End Sub
$M='System.Windows.Forms';nal n New-Object;Add-Type -A System.Drawing,$M;($a=n "$M.Form").backgroundimage=($b=n Drawing.Bitmap 300,300);0..299|%{$r=$_;0..299|%{$i=99;$k=$C=n numerics.complex($_/75-2),($r/75-2);while((($k=$k*$k).Magnitude-lt4)-and$i--){$k+=$C}$b.SetPixel($_,$r,-5e6*++$i)}};$a.Show()
Sub ito_Presto()
Application.ScreenUpdating = False
Range("A1:IW128").Clear
Cells.ColumnWidth = 2
Triangulons_un_1er_Octobre
Application.ScreenUpdating = True
End Sub
Sub Triangulons_un_1er_Octobre(Optional Waclaw_Franciszek_Sierpinski As String = "CéBO!")
Dim SunShine_Baby
Randomize 1600
SunShine_Baby = Choose(Int(7 * Rnd + 1), vbBlack, vbRed, vbBlue, vbGreen, vbYellow, vbMagenta, vbWhite)
Dim r As Range: Set r = Range("B2:IW128"): [DZ1] = 1
With r
.Formula = "=IF(SUM(A1:C1)=1,1,"""")"
.Value = .Value
With .Offset(-1).Resize(128)
.FormatConditions.Add 1, 3, "=1"
.FormatConditions(1).Interior.Color = SunShine_Baby
End With
End With
ActiveWindow.Zoom = 20
End Sub