bonjour Je souhaite créer une dll qui doit être utilisé appelé depuis Labview , la compilation fonctionne bien mais j'ai un problème quand je souhaite enregistrer la DLL
Ai je oublié une option dans la compilation
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
Option Strict Off
Option Explicit On
<System.Runtime.InteropServices.ProgId("GenerateAndSort_NET.GenerateAndSort")> Public Class GenerateAndSort
    Public Sub BubbleSort(ByRef sortArray() As Short)
        Dim i As Short
        Dim j As Short
        Dim temp As Short
 
        'The familiar "Bubble Sorting" Algorithm
        For i = LBound(sortArray) To UBound(sortArray)
            For j = LBound(sortArray) To (UBound(sortArray) - i - 1)
                If sortArray(j + 1) < sortArray(j) Then
                    temp = sortArray(j) 'swap if the two items
                    sortArray(j) = sortArray(j + 1) 'are out of order
                    sortArray(j + 1) = temp
                End If
            Next j
        Next i
    End Sub
 
    Public Sub GenerateNumbers(ByRef genArray() As Short)
        Dim i As Short
 
        'Assign a random integer ranging from 0 to 100 to each element of "genArray"
        For i = LBound(genArray) To UBound(genArray)
            genArray(i) = Int(Rnd() * 101)
        Next i
 
    End Sub
End Class