Visualizzazione dei risultati da 1 a 2 su 2
  1. #1
    Utente di HTML.it
    Registrato dal
    Aug 2006
    Messaggi
    35

    [HELP] Utilizzo codice VBA su Excel

    Salve a tutti utilizzo Office 2007 e vorrei sapere come utlizzare il seguente codice:

    codice:
      Private Sub Worksheet_Change(ByVal Target As Range)
    If Target.Text = "" Then
    Exit Sub
    End If
    If Target.Value > 1 Then
    Exit Sub
    End If
    If Target.Style = "Percent" Then
    Dim forma As Shape
    For Each forma In Target.Worksheet.Shapes
    If forma.Name = Target.Address Then
    forma.Delete
    Exit For
    End If
    Next
    Set forma = Target.Worksheet.Shapes.AddShape(msoShapeRectangle, Target.Left, Target.Top, Target.Width * Target.Value, Target.Height)         forma.Name = Target.Address
    With forma
    .Line.Visible = False
    .Fill.Transparency = 0.5
    .Fill.ForeColor.RGB = RGB((Int(255 * Target.Value)), 255 - (Int(255 * Target.Value)), 0)
    End With
    End If
    End Sub
    Che so essere utilizzato per visualizzare un Riempimento Percentuale delle Celle.
    Sono totalmente estraneo alla procedura di inserimento in un foglio excel e alla relativa attivazione.
    Potreste aiutarmi illustrandomi passo passo come fare?

    Insieme alla spiegazione si accettano file gia pronti all'uso qualora la sola spiegazione sia troppo difficile

  2. #2
    Moderatore di Windows e software L'avatar di darkkik
    Registrato dal
    Dec 2003
    residenza
    Pavia - Milano - Lodi.
    Messaggi
    11,476
    Le discussioni con HELP nel titolo vengono chiuse come da regolamento.

    Se vuoi riapri una nuova con un titolo conforme.
    I can see much clearer now, I'm blind.
    Io fui già quel che voi siete, Quel ch'io son voi anco sarete.
    Remember that death is not the end, but only a transition
    All that we learn this time is carried beyond this life.

Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire repliche
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Powered by vBulletin® Version 4.2.1
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.