468,740 Members | 2,132 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 468,740 developers. It's quick & easy.

What do all the commas mean

25
if a code is written like below what does it mean:

Expand|Select|Wrap|Line Numbers
  1. project1.openform form1 ,,,,
i'm mainly concerned about the commas wat do they imply and what can be put after these commas
Oct 3 '07 #1
3 1764
code937
24
at a complete guess its just empty variables...
Oct 3 '07 #2
hariharanmca
1,977 1GB
Can you explain what version of VB you are using?
Oct 3 '07 #3
SammyB
807 Expert 512MB
if a code is written like below what does it mean:

Expand|Select|Wrap|Line Numbers
  1. project1.openform form1 ,,,,
i'm mainly concerned about the commas wat do they imply and what can be put after these commas
OpenForm has seven parameters. all of which are optional except the first one, which is the form name, so your commas just indicate that there are missing parameters, but white space works just as well and is not as confusing. So, assuming you have a form named Form1, your line of code should be:
Expand|Select|Wrap|Line Numbers
  1.  DoCmd.OpenForm "Form1"
  2.     or better
  3. DoCmd.OpenForm Form1.Name
  4.     or you could add some commas, but nobody does
  5. DoCmd.OpenForm Form1.Name,,,,,,
  6.     unless you wanted to use one of the optional parameters:
  7. DoCmd.OpenForm Form1.Name,,,"LastName = 'Smith'"
  8.     but a better way is
  9. DoCmd.OpenForm FormName:=Form1.Name, WhereCondition:="LastName = 'Smith'"
  10.  
see http://msdn2.microsoft.com/en-us/library/bb238021.aspx for more details on OpenForm
Oct 4 '07 #4

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

14 posts views Thread by Mike N. | last post: by
5 posts views Thread by greenflame | last post: by
7 posts views Thread by AES | last post: by
53 posts views Thread by Deniz Bahar | last post: by
3 posts views Thread by Robert Scheer | last post: by
4 posts views Thread by Giggle Girl | last post: by
14 posts views Thread by Adrienne Boswell | last post: by
reply views Thread by zhoujie | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.