473,405 Members | 2,167 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

If condition without operator's Else

1
What is meaning for .

If you set If like this

If RsData.RecordCount Then
Combo1.Tag = RsData.AbsolutePosition Else Exit Sub

If RsData.RecordCount

what ??? <> < > = >= <= ?
Sep 8 '14 #1
1 986
twinnyfo
3,653 Expert Mod 2GB
t3cho,

First, please use code tags when posting code.

Second, the format of your code will produce an error, as there is no "End" included int he statement, and the Else must be on a separate line. This could all simply be formatting as posted.

Third, I am not sure what you question is.

If you are asking what the line

Expand|Select|Wrap|Line Numbers
  1. If RsData.RecordCount
does, then this line is checking to see the current record count of the recordset. If this recordset has just been opened, it should be on the first record (if the recordset is not empty), and so the record count will be one. If code has previously worked with the recordset, and, for example, has moved to the last record, then the value will be the total number of records.

Because If...Then statements evaluate Boolean conditions, if there are no records in the recordset, then RsData.RecordCount will return 0, which is equivalent to "False", and the following statements in the If...Then sonctruct will not fire.

If there are any records, then RsData.RecordCount will be a numerical value, and any numerical value (other than 0) will evaluate to "True", and the following statements will fire.

Other than that, I am not sure what you are asking.
Sep 9 '14 #2

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

Similar topics

27
by: Ron Adam | last post by:
There seems to be a fair amount of discussion concerning flow control enhancements lately. with, do and dowhile, case, etc... So here's my flow control suggestion. ;-) It occurred to me (a...
3
by: Patrice | last post by:
Hi, I need to do multi-conditional statements like below, but this error is displayed : Expected 'End' /myFilepath, line x else response.write(arrCorpo(sparam,sdiv)) end if I don't...
6
by: Marcus | last post by:
I have the following scenario. I am trying to run a query where a student's address will be pulled from a table if the student's address has been selected as "preferred". If no "preferred"...
25
by: David Sanders | last post by:
Hi, As part of a simulation program, I have several different model classes, ModelAA, ModelBB, etc., which are all derived from the class BasicModel by inheritance. model to use, for example...
12
by: why? | last post by:
I've been having problem with the following code. It's supposed to print the prime numbers between 10 and 100. But i'm not getting any output, i.e. i guess the outer 'for' loop is being traversed...
11
by: Chad | last post by:
The question stems from some code at the following url http://www.cplusplus.com/reference/clibrary/cstdio/fread.html In the code example they have a single if statement for the following ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.