Pascal/Turbo Pascal - Ayuda Software de inventario para culminar

 
Vista:
sin imagen de perfil

Ayuda Software de inventario para culminar

Publicado por Cesar (5 intervenciones) el 20/01/2016 15:50:00
Necesito ayuda para terminar este programa en la parte de facturacion sera que alguien me puede ayudar
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder
sin imagen de perfil

Ayuda Software de inventario para culminar

Publicado por crack81 (58 intervenciones) el 22/01/2016 02:57:03
ayudarte en que ?
necesitas darnos informacion ya que no podemos adivinar
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
1
Comentar
sin imagen de perfil

Ayuda Software de inventario para culminar

Publicado por Cesar (5 intervenciones) el 22/01/2016 14:58:53
Necesito terminar la opcion de facturacion pero no estoy a conseguir si alguien consigue ayudar a terminar esa opcion
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar
sin imagen de perfil

Ayuda Software de inventario para culminar

Publicado por Cesar (5 intervenciones) el 23/01/2016 18:46:33
mi problema es q no graba la informacion en el archivo correspondiente pueden ayudar es urgente tengo q entregar esto el lunes

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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
type
.
.
.
.
.
.
    Factura = record
              cli: word;
              fecha   : string[15];
              RifCed  : string[15];
              Nombre  : string[35];
              ap      : string[35];
              tel     : string[15];
              Dir     : string;
              Codpro  : word;
              Descrip  : string[45];
              Canti : word;
              Precio: word;
              total: integer;
    end;
 
 
var
   archivo1     : file of persona;
   archivo2     : file of producto;
   archivo3     : file of factura;
   cliente      : persona;
   productos    : producto;
   facturas     : factura;
   opcion5      : char;
   a,b          : byte;
   dow          : word;
   car          : word;
   pro          : word;
   numfact      : word;
   control      : char;
   total,totalinea,cantiv,e,me,d,ds:word;
   x: integer;
   valoriva: integer;
.
.
.
.
.
.
 
{***********PROCESO PARA FACTURA NUEVA****************}
Procedure factnuevo;
  begin
    assign(Archivo3,'facturas.dat');
    reset(archivo3);
    seek(archivo3,filesize(archivo3));
    with facturas do
       begin
       textcolor(white);
       gotoxy(5,5);
       writeln ('# Factura: ');
       gotoxy(16,5);
       writeln(filepos(archivo3)+1);
       gotoxy(50,5);
       getdate(e,me,d,ds);
       write ('Fecha: ', d,' - ', me,' - ',e);
       control:= 'b';
     repeat
         gotoxy(5,6);
         textcolor(white);
         writeln ('# Cliente: ');
         gotoxy(16,6);
         readln (car);
         assign(archivo1,'clientes.dat');
         reset(archivo1);
      begin
         while not eof(archivo1) do
         begin
            read(archivo1,cliente);
            with cliente do
                 begin
                   if (car) = filepos(archivo1) then
                      begin
                           control := 'a';
                           gotoxy(5,7);
                           writeln ('Nomb: ',nombre, ' ',ap);
                           gotoxy(5,8);
                           writeln ('Rif/Ced: ',rifced);
                           gotoxy(50,9);
                           writeln ('Telf.: ',tel);
                           gotoxy(5,9);
                           writeln ('Dirc.: ',dir);
                      end
                 end
 
 
                 end;
                 write(archivo3,facturas);
                 textcolor(white);
 
         end;
         until control= 'a';
       gotoxy(5,11);
       writeLN('ÚÄÄÄÄÄÄÄÄÂÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÂÄÄÄÄÄÄÄÂÄÄÄÄÄÄÄÄÂÄÄÄÄÄÄÄ¿');
       gotoxy(5,12);
       textcolor(14);
       writeln ('³Cod.Prod.             Descripcion          Precio   Cantd.   Total');
       textcolor(white);
       gotoxy(5,12);
       writeln ('³');
       gotoxy(14,12);
       writeln('³');
       gotoxy(48,12);
       writeln('³');
       gotoxy(56,12);
       writeln('³');
       gotoxy(65,12);
       writeln('³');
       gotoxy(73,12);
       writeln('³');
       gotoxy(5,13);
       write ('ÃÄÄÄÄÄÄÄÄÅÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÅÄÄÄÄÄÄÄÅÄÄÄÄÄÄÄÄÅÄÄÄÄÄÄÄ´');
   end;
   x:=14;
   REPEAT
   totalinea:=0;
   gotoxy(5,x);
   write ('³');
   gotoxy(7,x);
   readln(pro);
          control:= 'b';
     repeat
         assign(Archivo2,'productos.dat');
         reset(archivo2);
      begin
         while not eof(archivo2) do
         begin
            read(archivo2,productos);
            with productos do
                 begin
                   if (pro) = filepos(archivo2) then
                      begin
                           control := 'a';
                           gotoxy(14,x);
                           write ('³ ',descrip);
                           gotoxy(48,x);
                           write ('³ ',precio);
                           gotoxy(56,x);
                           write ('³ ');
                           readln(cantiv);
                      canti:=canti-cantiv;
                      seek(archivo2,filepos(archivo2)-1);
                      write(archivo2,productos);
                      textcolor(white);
                      totalinea:= cantiv*precio;
                      gotoxy(65,x);
                      write ('³ ',totalinea);
                      total:=totalinea+total;
                      gotoxy(73,x);
                      write ('³');
 
                      end
 
                 end
 
                 end;
 
         end;
         until control= 'a';
 
   x:=x+1;
   UNTIL x=19;
   gotoxy(5,19);
   writeln ('ÀÄÄÄÄÄÄÄÄÁÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÁÄÄÄÄÄÄÄÁÄÄÂÄÄÄÄÄÁÄÄÄÄÄÄÄ´');
   gotoxy(41,20);
   writeln ('Total  ÄÄÄÄÄ >>   ³');
   gotoxy(73,20);
   writeln ('³');
   gotoxy(63,20);
   writeln (total);
   gotoxy(59,21);
   writeln ('ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÙ');
 
   write(archivo3,facturas);
   close(Archivo3);
 
   readln;
 
 
    end;
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar
sin imagen de perfil

Ayuda Software de inventario para culminar

Publicado por Cesar (5 intervenciones) el 23/01/2016 18:56:19
si puedes ayudar te lo agradezco estoy pero super parado y ando full de trabajo y no estoy a conseguir ver el error si puedes ayudar te lo agradezco
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

Ayuda Software de inventario para culminar

Publicado por ramon (2158 intervenciones) el 25/01/2016 13:01:11
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
{Mira esto}
 
  Factura = record
              cli: word;
              fecha   : string[15];
              RifCed  : string[15];
              Nombre  : string[35];
              ap      : string[35];
              tel     : string[15];
              Dir     : string;
              Codpro  : word;
              Descrip  : string[45];
              Canti : word;
              Precio: word;
              total: integer;
    end;
 
 
var
   archivo1     : file of persona;
   archivo2     : file of producto;
   archivo3     : file of factura;
   cliente      : persona;
   productos    : producto;
   facturas     : factura;
   opcion5      : char;
   a,b          : byte;
   dow          : word;
   car          : word;
   pro          : word;
   numfact      : word;
   control      : char;
   total,totalinea,cantiv,e,me,d,ds:word;
   x: integer;
   valoriva: integer;
 
 peocedure cargadatos(dd :Factura);
 var
   cont : longint;
  begin
     assign(archivo3,'factura.dat');
  {$I-} reset(archivo3); {$I+}
   if ioresult <> 0 then
   begin
     rewrite(archivo3);
     seek(archivo3,0);
     write(archivo3,dd);
     close(archivo3);
   end
 else
   begin
      seek(archivo3,filesize(archivo3));
      write(archivo3,dd);
      close(archivo3);
    end;
  end;
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar