This commit is contained in:
DESKTOP-E401PHE\Administrator 2025-09-29 09:26:58 +08:00
parent 1bd28e3cdf
commit 9e47254929
3 changed files with 41 additions and 10 deletions

View File

@ -101,7 +101,7 @@ DebugSourceDirs=
UsePackages=0
[Parameters]
RunParams=
HostApplication=D:\徐加艳项目代码\项目代码\蔚勉\打卷检验管理\testDll.exe
HostApplication=D:\Dp7Repo\项目代码\D7DJweimian\打卷检验管理\testDll.exe
Launcher=
UseLauncher=0
DebugCWD=

View File

@ -4,7 +4,21 @@ interface
uses
SysUtils, Classes, DB, ADODB, ImgList, Controls, cxStyles, cxLookAndFeels,
Windows,Messages,forms,OleCtnrs,DateUtils, cxClasses, ExtCtrls,SyncObjs;
Windows,Messages,forms,OleCtnrs,DateUtils, cxClasses, ExtCtrls,SyncObjs,
dxSkinsCore, dxSkinBlack, dxSkinBlue, dxSkinBlueprint, dxSkinCaramel,
dxSkinCoffee, dxSkinDarkRoom, dxSkinDarkSide, dxSkinDevExpressDarkStyle,
dxSkinDevExpressStyle, dxSkinFoggy, dxSkinGlassOceans,
dxSkinHighContrast, dxSkiniMaginary, dxSkinLilian, dxSkinLiquidSky,
dxSkinLondonLiquidSky, dxSkinMcSkin, dxSkinMetropolis,
dxSkinMetropolisDark, dxSkinMoneyTwins, dxSkinOffice2007Black,
dxSkinOffice2007Blue, dxSkinOffice2007Green, dxSkinOffice2007Pink,
dxSkinOffice2007Silver, dxSkinOffice2010Black, dxSkinOffice2010Blue,
dxSkinOffice2010Silver, dxSkinOffice2013DarkGray,
dxSkinOffice2013LightGray, dxSkinOffice2013White, dxSkinPumpkin,
dxSkinSeven, dxSkinSevenClassic, dxSkinSharp, dxSkinSharpPlus,
dxSkinSilver, dxSkinSpringTime, dxSkinStardust, dxSkinSummer2008,
dxSkinTheAsphaltWorld, dxSkinsDefaultPainters, dxSkinValentine,
dxSkinVS2010, dxSkinWhiteprint, dxSkinXmas2008Blue;
type
TMyThread = class(TThread)
protected

View File

@ -23,7 +23,7 @@ uses
dxSkinSevenClassic, dxSkinSharp, dxSkinSharpPlus, dxSkinSilver,
dxSkinSpringTime, dxSkinStardust, dxSkinSummer2008, dxSkinTheAsphaltWorld,
dxSkinsDefaultPainters, dxSkinValentine, dxSkinVS2010, dxSkinWhiteprint,
dxSkinXmas2008Blue, dxSkinscxPCPainter;
dxSkinXmas2008Blue, dxSkinscxPCPainter,StrUtils;
type
TfrmMJManageNewFDNewSF = class(TForm)
@ -1766,7 +1766,7 @@ end;
procedure TfrmMJManageNewFDNewSF.PrtData(FMJID: string);
var
fPrintFile: string;
Txt, fImagePath: string;
Txt, fImagePath, Txt1, fImagePath1: string;
Moudle: THandle;
Makebar: TMakebar;
Mixtext: TMixtext;
@ -1796,12 +1796,12 @@ begin
Open;
end;
try
Moudle := LoadLibrary('MakeQRBarcode.dll');
@Makebar := GetProcAddress(Moudle, 'Make');
@Makebar := GetProcAddress(Moudle, 'Make');
@Mixtext := GetProcAddress(Moudle, 'MixText');
Txt := Trim(ADOQueryPrint1.fieldbyname('¾íÌõÂë').AsString);
Txt := Trim(ADOQueryPrint1.fieldbyname('卷条码').AsString);
Txt := Trim(ADOQueryPrint.fieldbyname('MJID').AsString);
fImagePath := ExtractFilePath(Application.ExeName) + 'image\temp.bmp';
if not DirectoryExists(pchar(ExtractFilePath(Application.ExeName) + 'image')) then
@ -1815,6 +1815,23 @@ begin
exit;
end;
try
Moudle := LoadLibrary('MakeQRBarcode.dll');
@Makebar := GetProcAddress(Moudle, 'Make');
@Mixtext := GetProcAddress(Moudle, 'MixText');
Txt1 := Trim(ADOQueryPrint.fieldbyname('orderno').AsString) + '/' + Trim(ADOQueryPrint.fieldbyname('prtcolor').AsString) + '/' + RightStr(('10000' + trim(ADOQueryPrint.fieldbyName('MJXH').AsString)), 4) + '/' + (format('%.1f', [( ADOQueryPrint.fieldbyname('Mjlen').AsFloat) ]));
Txt1 := UTF8Encode(Txt1);
fImagePath1 := ExtractFilePath(Application.ExeName) + 'image\temp1.bmp';
if not DirectoryExists(pchar(ExtractFilePath(Application.ExeName) + 'image')) then
CreateDirectory(pchar(ExtractFilePath(Application.ExeName) + 'image'), nil);
if FileExists(fImagePath1) then
DeleteFile(fImagePath1);
Makebar(pchar(Txt1), Length(Txt1), 3, 3, 0, PChar(fImagePath1), 3);
except
application.MessageBox('条形码生成失败!', '提示信息', MB_ICONERROR);
CDS_MJID.EnableControls;
exit;
end;
if Trim(ADOQueryPrint.fieldbyname('Slbname').AsString) <> '' then
begin
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\' + Trim(ADOQueryPrint.fieldbyname('Slbname').AsString);
@ -1878,7 +1895,7 @@ begin
begin
RMVariables['QRBARCODE'] := fImagePath;
RMVariables['QRBARCODE1'] := fImagePath1;
if Edit5.Text <> '' then
begin
RM3.LoadFromFile(fPrintFile);
@ -2980,12 +2997,12 @@ procedure TfrmMJManageNewFDNewSF.TBCDClick(Sender: TObject);
var
fPrintFile: string;
i: Integer;
begin
begin
if CDS_MJID.IsEmpty then
Exit;
MggCDFalg := '99';
CDS_MJID.DisableControls;
with CDS_MJID do
with CDS_MJID do
begin
First;
while not Eof do