lo he intentado adaptar a mi programa y asi es mas o menos como me quedo, pero me da un error: Error de Sintaxis en la instrucción INSERT INTO
la tabla de datos esta en access y tiene los siguientes campos:
CodFactura
fecha
CodCliente
CodArticulo
Descripción
Cantidad
MontoTotal
el código es el siguiente:
Código Delphi
[-]
Var
a,b,c : real;
begin
a:= StrTofloat(cantidad.Text);
b:= StrTofloat(preciounitario.Text);
c:= a * b;
total.Text:= floatToStr(c);
qry1.SQL.Text := 'Insert into Factura values ('+QuotedStr(CodFactura.Text)+', :fecha, '+QuotedStr(CodCliente.Text)+ ', '+QuotedStr(CodArticulo.Text)+ ', '+Descripcion.Caption+ ', '+
QuotedStr(Cantidad.Text)+ ', '+QuotedStr(Total.Text);
qry1.Parameters.ParamByName('fecha').Value:= DateToStr(Dtp1.Date);
qry1.ExecSQL;
end;