Senin, 15 April 2013

Re: [MS_AccessPros] VBA question

 

Dear Glenn,
Yes, <50 should include everything that is less than 50 and <30 should include everything thant is less than 30 but this is not happening. How to achieve this? Please guide.

Kind Regards,
Kumar

--- In MS_Access_Professionals@yahoogroups.com, "Glenn Lloyd" <argeedblu@...> wrote:
>
> <50 includes everything that is less than 50. <30 would include everything
> but 50. If you want to filter for 30 and 50 then you would use >=30
>
>
>
> Glenn
>
>
>
> From: MS_Access_Professionals@yahoogroups.com
> [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of access_kri
> Sent: Monday, April 15, 2013 4:45 AM
> To: MS_Access_Professionals@yahoogroups.com
> Subject: [MS_AccessPros] VBA question
>
>
>
>
>
> Dear All,
> I have a database that uses statuscode 10,20,30,40 and 50 to denote
> Reported, Planned, Scheduled, inprogress and completed respectively. The
> statuscode field is long integer data type. I have a search cum entry
> continuous form. In the unbound search combobox cboStatusCode, I have
> entered value list as 10,20,30,40,50, <30, <50 to where <30 indicates
> unscheduled job and <50 indicates unfinished jobs.
>
> I am able to use the searchbox cboStatuscode to filter the form based on
> status of the job but when I use <30 and <50, it does not filter the joblist
> for unscheduled and unfinished jobs. Why?
>
> I am using the following VBA for the same.
> If Not IsNull(Me.cboSearchStatus) Then
> strWhere = strWhere & "([StatusCode] Like """ & Me.[cboSearchStatus] & """)
> AND "
> End If
>
> If Me.cboSearchStatus = "<50" Then
> strWhere = strWhere & "([StatusCode]<50) AND "
> End If
>
> If Me.cboSearchStatus = "<30" Then
> strWhere = strWhere & "([StatusCode]<30) AND "
> End If
>
> ----
> Thanks and Regards,
> Kumar
>
>
>
>
>
> [Non-text portions of this message have been removed]
>

__._,_.___
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (15)
Recent Activity:
.

__,_._,___

Tidak ada komentar:

Posting Komentar