Jump to content

Barcode Convert


Nr31s
 Share

Recommended Posts

Hi,

Someone can give me a hand to help to create a free tool for convert, display, print, preview and generate barcodes????

Well i have made already some hints to get my own generator number, but the problem is to convert the decimal number to ean13...

Thanks for all the help.

Link to comment
Share on other sites

Hi,

Someone can give me a hand to help to create a free tool for convert, display, print, preview and generate barcodes????

Well i have made already some hints to get my own generator number, but the problem is to convert the decimal number to ean13...

Thanks for all the help.

CODE

#include <GUIConstants.au3>

Dim $PS, $szDrive, $szDir, $szFName, $szExt

Const $File = FileOpen(@ScriptDir & "\Barcode.ps", 2)

Dim $out = -1

Const $i = _GenerateSerialNumber()

Opt("GUIOnEventMode", 1)

#Region ### START Koda GUI section ### Form=

$Form1 = GUICreate("Form1", 178, 96, 318, 100)

GUISetOnEvent($GUI_EVENT_CLOSE, "Form1Close")

GUISetOnEvent($GUI_EVENT_MINIMIZE, "Form1Minimize")

GUISetOnEvent($GUI_EVENT_RESTORE, "Form1Restore")

$cmdgen = GUICtrlCreateButton("Generate", 16, 48, 121, 17, 0)

GUICtrlSetOnEvent(-1, "cmdgenClick")

$cmdprint = GUICtrlCreateButton("Print", 16, 68, 121, 17, 0)

$lbl = GUICtrlCreateLabel("", 24, 24, 150, 20)

GUISetState(@SW_SHOW)

#EndRegion ### END Koda GUI section ###

While 1

Sleep(100)

WEnd

Func _GenerateSerialNumber()

$out = $out + 1

$SerialNumber = "1" & StringMid(@YEAR & @MON & @MDAY, 3) & $out

If $out > 9 Then

;GUICtrlSetState($cmdgen,$GUI_DISABLE)

$out = -1

EndIf

Return $SerialNumber

EndFunc

Func cmdgenClick()

GUICtrlSetData($lbl,"")

GUICtrlSetData($lbl,_GenerateSerialNumber())

EndFunc

Func cmdprintClick()

; LONG CODE

EndFunc

Func Form1Close()

Exit

EndFunc

Link to comment
Share on other sites

Hi,

Someone can give me a hand to help to create a free tool for convert, display, print, preview and generate barcodes????

Well i have made already some hints to get my own generator number, but the problem is to convert the decimal number to ean13...

Thanks for all the help.

Don't know anything about barcodes, but the printing part sounds like a suitable job for my print udf, (see my signature) though it also needs my dll so it isn't pure AutpIt.

Previewing in AutoIt would be quite easy using GUICtrlSetGraphic.

Converting the number to ean13 looks like just a question of following the spec. (I'm not volunteering though.)

Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script.
Link to comment
Share on other sites

  • 4 years later...
  • Moderators

harkgreen,

Did you realise that the post above yours dates back nearly 5 years? :huh:

We discourage necro-posting that far back as the language has changed so much since then that the code is very unlikely to be runnable and/or the problem has been solved in another more recent thread. Please take a moment to check the date when you post again. ;)

M23

Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...