Wrox Programmer Forums
|
Access VBA Discuss using VBA for Access programming.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Access VBA section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old December 22nd, 2009, 02:39 PM
Registered User
 
Join Date: Dec 2009
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default MOD36 check digit

Hello all,,

I am a totally beginner in Access, I like to think that I’m a fast learner but I’m stocked with this database for weeks now and mod36 check digit isn’t the only issue, but I thought its better to go one thing at the time, so maybe its better for me to explain once again what I’m trying to accomplish in here, so it will be easier for you to help me. I have a form and in that form I have a Text field (Text1) where I generate a random number like this:

Default Value ="GYM01" & Int((9999999-1000000+1)*Rnd()+1000000)

so i have a 15 characters random string, for example (GYM012547787854)

now, I have another text field (Text2) where I need to add the mod36 check digit to this 15 characters string I generated, meaning in this Text2 I would like to have GYM012547787854 + (check digit, that can be 0 to 9 or A to Z) for example after the "formula or code" it should bring GYM0125477878547 (automatically generated complete 16 digit reference code that I need)

So I’m pretty sure that you can do this, the only thing is for me to know how to put all the code in place

I really appreciate your help and thank you for your time.

Sincerely

toqilula
 
Old December 28th, 2009, 10:01 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 2,189
Thanks: 5
Thanked 59 Times in 57 Posts
Send a message via MSN to gbianchi
Default

Hi there..

Why are you doing this??? (9999999-1000000+1)???

Anyway, you need to append the control char to your string?? you can use & to append strings.

What do you mean with all the code in place???
__________________
HTH

Gonzalo


================================================== =========
Read this if you want to know how to get a correct reply for your question.
(Took that from Doug signature and he Took that from Peter profile)
================================================== =========
My programs achieved a new certification :
WORKS ON MY MACHINE
================================================== =========
I know that CVS was evil, and now i got the
proof.
================================================== =========





Similar Threads
Thread Thread Starter Forum Replies Last Post
remove the first digit in xml Nagaraj XSLT 6 May 6th, 2009 12:23 PM
remove the first digit in xml Nagaraj XSLT 1 May 5th, 2009 12:25 AM
Extract a digit from specified position sektor Visual Basic 2005 Basics 10 June 9th, 2008 05:05 PM
7 Digit number jemacc SQL Server 2000 3 April 4th, 2004 01:02 AM
How to keep two digit after float number? Edward King Javascript 1 July 30th, 2003 01:12 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.