Novità

Mente da programmatore

luigi sono riuscito a rinominare il file , ma lo apre con vb2015 che non ho pi l ho eliminato mi chiede di prendere la licenza.
perche no lo apre con community?
 
scusa legend sscaricalo da qui , allora .. cosi è gia rar

 
mha io ho scaricato il file scompattato e fatto doppio click su

1636216782051.png


e si apre tranquillamente .. manda la schermata dell'errore
 
In esplora soluzioni
Winformsapp2( Non trovato )
In output
Non è stato possibile caricare il file di progetto
Impossibile trovare una parte del percorso ecc
 
bha .. mistero .. allora crea tu un nuovo progetto seguendo le istruzioni di qualche post fa

sul form devi mettere una listbox , un pulsante e una text box

poi fai doppio click sul pulsante e inserisci queste righe solo quelle blue quelle nere servono per fart ivedere dove le devi inserire

Codice:
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
        Dim aN() As Integer
        Dim q As Integer

        q = StringaNumToArrayNum(TextBox1.Text, aN)

        ListBox1.Items.Clear()
        For k As Integer = 1 To q
            ListBox1.Items.Add(aN(k))


        Next

        MsgBox("Numeri totali " & q)


    End Sub

poi aggiungi un modulo al progetto , aprilo e incolla queste altre righe e manda in run il progetto

Codice:
Public Function StringaNumToArrayNum(sNumeri As String, ByRef aRetN() As Integer) As Integer
        Dim sChr As String
        Dim sValue As String = ""
        Dim q As Integer
        Dim n As Integer


        ReDim aRetN(90)

        For k As Integer = 0 To sNumeri.Length - 1
            sChr = sNumeri.Substring(k, 1)
            If IsNumeric(sChr) Then
                sValue = sValue & sChr
            Else
                If sValue.Trim <> "" Then
                    n = Convert.ToInt32(sValue)
                    If n >= 0 And n <= 90 Then
                        q += 1
                        aRetN(q) = n
                    End If
                    sValue = ""
                End If

            End If
        Next

        If sValue.Trim <> "" Then
            n = Convert.ToInt32(sValue)
            If n >= 0 And n <= 90 Then
                q += 1
                aRetN(q) = n
            End If
            sValue = ""
        End If


        ReDim Preserve aRetN(q)
        Return q

    End Function
    Public Function StringaNumToArrayNum(sNumeri As String, ByRef aRetN() As Boolean) As Integer

    End Function
 
praticamente identica ho solo valorizzaTO a fals e l array e poi i numeri a true
avrei dovuto fare questo.
cmq ho bisogno anche di studiare.
grazie prof :)
Codice:
   Public Function StringaNumToArrayNum(sNumeri As String, ByRef aRetN() As Boolean) As Integer
        Dim sChr As String
        Dim sValue As String = ""
        Dim q As Integer
        Dim n As Integer


        ReDim aRetN(90)
        For n = 0 To 90
            aRetN(n) = False

        Next

        For k As Integer = 0 To sNumeri.Length - 1
            sChr = sNumeri.Substring(k, 1)
            If IsNumeric(sChr) Then
                sValue = sValue & sChr
            Else
                If sValue.Trim <> "" Then
                    n = Convert.ToInt32(sValue)
                    If n >= 0 And n <= 90 Then
                        q += 1
                        aRetN(n) = True
                    End If
                    sValue = ""
                End If

            End If
        Next

        If sValue.Trim <> "" Then
            n = Convert.ToInt32(sValue)
            If n >= 0 And n <= 90 Then
                q += 1
                aRetN(n) = True
            End If
            sValue = ""
        End If


        '   ReDim Preserve aRetN(q)
        Return q
    End Function
 
Ultima modifica:
Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
ListBox1.Items.Clear()
TextBox1.Clear()
End Sub
cosi pulisco tutto
 

Ultima estrazione Lotto

  • Estrazione del lotto
    martedì 12 agosto 2025
    Bari
    24
    68
    73
    16
    76
    Cagliari
    78
    24
    82
    32
    90
    Firenze
    39
    46
    21
    45
    28
    Genova
    50
    03
    21
    64
    09
    Milano
    85
    44
    38
    43
    34
    Napoli
    12
    16
    56
    61
    03
    Palermo
    75
    64
    34
    25
    28
    Roma
    55
    29
    43
    06
    64
    Torino
    38
    60
    90
    53
    82
    Venezia
    12
    75
    34
    67
    77
    Nazionale
    70
    17
    25
    41
    57
    Estrazione Simbolotto
    Nazionale
    25
    28
    19
    34
    36

Ultimi Messaggi

Indietro
Alto