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 November 12th, 2006, 01:49 PM
Friend of Wrox
 
Join Date: Jul 2003
Posts: 128
Thanks: 0
Thanked 0 Times in 0 Posts
Default What these Codes Mean?

Hi,
I use Access alot, but mostly the basic stuff. Now I am trying to learn some VB Script to expand my Access skills. I saw codes that I am not too sure of what they do. Please advice.

Do Until rst.EOF
With rst
vcount=vcount + 1
vtc = !tblColumn
End With
Loop
What does this codes do?



Another question:
vsql3 = "Group By SSN, [Group], " & vsta
What does this do? Particularly [Group]?

Thank you.

 
Old November 14th, 2006, 08:50 AM
Friend of Wrox
 
Join Date: Mar 2004
Posts: 3,069
Thanks: 0
Thanked 10 Times in 10 Posts
Default

The first set of code lines is working ona recordset. It is looping through the recordset, and for each record, it is advancing the counter vcount by 1, and taking a value from tblColumn. This looks like DAO though, and I don't do that much.

The second set of code lines is assigning a text value to the variable vsql3. If you output vsql3 to the screen, you would get:

Group By SSN, [Group], vstaValue (which is a number)

[Group] is a field name. This is supplying a Group By clause to a SQL Select statement.

Does that help?
You should read some Wrox books on VBA.


mmcdonal





Similar Threads
Thread Thread Starter Forum Replies Last Post
Help for moto AT codes please. Mohammed C# 2 November 13th, 2006 05:00 AM
Need some more sample codes t.m.sundaram Visual Basic 2005 Basics 0 July 16th, 2006 08:16 AM
Please i need help with one of my codes skoob Java Espanol 1 April 11th, 2005 11:39 AM
Help:needs codes GoGoagg All Other Wrox Books 3 June 30th, 2004 01:24 AM
How do I merge these two codes? stacy Classic ASP Databases 1 March 22nd, 2004 04:30 AM





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