E.B.
Private Type NIVEAU id As Long ' Identifiant du niveau nbCols As Long ' Nombre de colonnes nbRows As Long ' Nombre de lignes name As String * 32 ' Titre ou nom du niveau startPosX As Long ' Position de démarrage du perso en X startPosY As Long ' Position de démarrage du perso en Y type As Long ' Bibliothèque graphique à charger backgroundImageURL As String * 255 ' Chemin relatif de l'image de fond pour l'affichage du niveau tableau(50, 30) As Long ' Tableau décrivant le niveau End Type Private Enum TYPE_GRAPHIQUE_DU_NIVEAU NIVEAU_CAVERNE = 0 NIVEAU_CHATEAU NIVEAU_CIEL NIVEAU_EGYPTE NIVEAU_FORET NIVEAU_JUNGLE NIVEAU_MAISON NIVEAU_MARE NIVEAU_PRAIRIE End Enum Sub creerFichier() Dim s As String Dim i, j As Long Dim n As NIVEAU s = "c:\toto.txt" 'App.Path & "\data" 'donnees bidons pour tester With n .backgroundImageURL = "images\toto.jpg" .id = 5 .name = "le monde de toto" .nbCols = 87 .nbRows = 46 .startPosX = 76 .startPosY = 65 For i = 0 To 50 For j = 0 To 30 .tableau(i, j) = i + j Next j Next i .type = CHATEAU End With ' fin des données bidons Dim Canal As Byte: Canal = FreeFile Open s For Binary As #Canal Len = Len(n) Put #Canal, , n ' L'erreur apparaît ici !!!! Close #Canal End Sub
E.B.
Vous n’avez pas trouvé la réponse que vous recherchez ?
Posez votre question