Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
RSB RSB is offline
external usenet poster
 
Posts: 5
Default Modulo 43 spreadsheet

How do I create a Modulo 43 spreadsheet in Excel 2003
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,391
Default Modulo 43 spreadsheet

Not sure what you mean by a "a Modulo 43 spreadsheet", but this function
calculates the check digit according to the Modulo 43 applied to the CODE 39
encoding logic.
You should add checks for valid input.

Public Function GetModulo43(CodeText As String) As String
Dim CharValues() As String
Dim i As Long
Dim RunSum As Long

Const Chars As String =
"0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F,G,H,I,J,K,L,M,N,O ,P,Q,R,S,T,U,V,W,X,Y,Z,-,.
, ,$,/,+,%"

CharValues = Split(Chars, ",")

For i = 1 To Len(CodeText)
RunSum = RunSum + Application.WorksheetFunction.Match(Mid(CodeText, i,
1), CharValues, 0) - 1
Next

GetModulo43 = CharValues(RunSum Mod 43)

End Function

NickHK

"RSB" wrote in message
...
How do I create a Modulo 43 spreadsheet in Excel 2003



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Help: Modulo... not... quite...right... Commish Excel Discussion (Misc queries) 3 September 6th 11 11:12 PM
link a local spreadsheet to a network shared spreadsheet Leo Setting up and Configuration of Excel 1 March 21st 08 10:37 AM
conversion of MS Works Spreadsheet to Excel 2002 Spreadsheet Kellie Excel Discussion (Misc queries) 1 March 24th 05 06:31 PM
Is there a way to insert a formula, password or macro in an excel spreadsheet that will automatically delete the spreadsheet? oil_driller Excel Discussion (Misc queries) 1 February 8th 05 09:34 AM
How to open another Excel spreadsheet to copy data into current spreadsheet ? Ricky Pang Excel Programming 0 July 13th 03 01:59 PM


All times are GMT +1. The time now is 06:56 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"