BOUCLE: CLS CLOSE : LOCATE 10, 10 INPUT ; "Saisir A$ (0 pour terminer) ", A$ IF VAL(A$) = 0 THEN END OPEN "fichier.txt" FOR OUTPUT AS #1 PRINT #1, A$ CLOSE OPEN "fichier.txt" FOR INPUT AS #2 INPUT #2, B$ LOCATE 12, 10: PRINT USING "###.##"; VAL(B$) SLEEP 5 GOTO BOUCLE
'G0X0.79Y2.57F500 (langage iso pour machine CNC) 'et actuellement j'ai : 'G0X .79 Y 2.57 F500 CLS A$ = "G0X": B# = .79: C$ = "Y": D# = 2.57 E$ = "F": F# = 500 ' Solution 1 PRINT A$; PRINT USING "#.##"; B#; PRINT C$; PRINT USING "#.##"; D#; PRINT E$; PRINT USING "###"; F# PRINT "G0X0.79Y2.57F500 (Recherche)" ' solution 2 (plus rapide ?) MASQUE$ = "&#.##!#.##!###" PRINT USING MASQUE$; A$; B#; C$; D#; E$; F#
chaine$ = str$(nombre#) chaine$ = LTRIM$(RTRIM$(chaine$)) PRINT "F1M61" + chaine$ +"etc...."