IRONSOFTWAREHOME
스타일 바코드
using IronBarCode;
using IronSoftware.Drawing;

// Create a barcode
var myBarcode = BarcodeWriter.CreateBarcode("12345", BarcodeWriterEncoding.EAN8);

// Resize in pixels
myBarcode.ResizeTo(400, 100);

// Set margins in pixels
myBarcode.SetMargins(5, 5, 5, 5);

// Set the color of the barcode
myBarcode.ChangeBarCodeColor(Color.Red);

// And save our barcode as an image:
myBarcode.SaveAsImage("EAN8.jpeg");

// Another supported feature is Mil Sizing
// Mil is a measurement unit used by the barcode scanner manufacturers to specify the minimum of one barcode bar, and at what distance the barcode can be scanned.
// It represents (1 / 1000)th of an inch
var barcodeResizeInMils = BarcodeWriter.CreateBarcode("5941623002802", BarcodeEncoding.Code128);

// This will resize the barcode width to 13 mil, at 96 DPI by default
barcodeResizeInMils.ResizeToMil(13);

// This will resize the barcode width to 10 mil and and the height to 1.5 inches, at 96 DPI by default
barcodeResizeInMils.ResizeToMil(10, 1.5);

// This will resize the barcode width to 7.5 mil and the height to 2 inches, with the DPI set to 200
barcodeResizeInMils.ResizeToMil(7.5, 2, 200);
Imports IronBarCode
Imports IronSoftware.Drawing

' Create a barcode
Dim myBarcode = BarcodeWriter.CreateBarcode("12345", BarcodeWriterEncoding.EAN8)

' Resize in pixels
myBarcode.ResizeTo(400, 100)

' Set margins in pixels
myBarcode.SetMargins(5, 5, 5, 5)

' Set the color of the barcode
myBarcode.ChangeBarCodeColor(Color.Red)

' And save our barcode as an image:
myBarcode.SaveAsImage("EAN8.jpeg")

' Another supported feature is Mil Sizing
' Mil is a measurement unit used by the barcode scanner manufacturers to specify the minimum of one barcode bar, and at what distance the barcode can be scanned.
' It represents (1 / 1000)th of an inch
Dim barcodeResizeInMils = BarcodeWriter.CreateBarcode("5941623002802", BarcodeEncoding.Code128)

' This will resize the barcode width to 13 mil, at 96 DPI by default
barcodeResizeInMils.ResizeToMil(13)

' This will resize the barcode width to 10 mil and and the height to 1.5 inches, at 96 DPI by default
barcodeResizeInMils.ResizeToMil(10, 1.5)

' This will resize the barcode width to 7.5 mil and the height to 2 inches, with the DPI set to 200
barcodeResizeInMils.ResizeToMil(7.5, 2, 200)
NuGet Download
PM > Install-Package BarCode
스타일 바코드

스타일 바코드

IronBarcode에서는 바코드를 크기를 조정하고, 여백을 추가하고, 색상을 변경하고, 다양한 인기 있는 파일 형식으로 저장할 수 있는 유연성이 있습니다. 게다가, 이미지의 세부 사항에 대한 보다 세밀한 제어를 달성하기 위해 DPI 설정을 조정할 수 있습니다.

바코드의 외형 사용자 지정: 바코드의 크기와 색상을 수정하는 다양한 방법:

  • ResizeTo(500, 500): 바코드를 500x500 픽셀로 크기 조정합니다.
  • ChangeBarColor: 바코드의 막대 색상을 변경합니다.
  • ChangeBackgroundColor: 배경색을 변경합니다.
IronBarcode로 바코드 스타일을 사용자 정의하는 방법 배우기
GitHub에서 보기

시작할 준비 되셨나요?

Nuget Downloads 2,422,100버전:2026.9방금 출시

Key in blue circle

무료 30일 체험 키를 즉시 받으세요.

Your trial license will be sent to your email address

제한 없음. 100% 무제한 이용. 신용카드 불필요.

bullet_checked신용카드나 계정 생성은 필요하지 않습니다.제한 없음. 100% 무제한 이용. 신용카드 불필요.
  • Logo Aetna
  • Logo NASA
  • Logo GE
  • Logo Porsche
  • Logo USDA
  • Logo Qatar
Join Millions of Engineers who’ve tried IronPDF
무료 라이브 데모를 예약하세요
Booking Badge

전 세계 수백만 엔지니어들이 신뢰하는 제품입니다.

Iron Software의 고객 로고
부담 없는 무료 상담을 받아보세요
아래 양식을 작성하시거나 sales@ironsoftware.com으로 이메일을 보내주세요.
고객님의 정보는 항상 비밀로 유지됩니다.
전 세계 수백만 엔지니어들이 신뢰하는 제품입니다.
Iron Software의 고객 로고
지금 바로 30일 무료 체험판 키를 받으세요.
신용카드나 계정 생성은 필요하지 않습니다.