User Profile

Collapse

Profile Sidebar

Collapse
Gari
Gari
Last Activity: Jan 8 '08, 06:17 AM
Joined: Jan 8 '07
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • Gari
    replied to Build a filter query with AND and OR statement
    I have worked out this:

    Code:
    SELECT tblProspects.CompName, tblProspects.Status, tblProspects.AOName, tblProspects.GroupName, tblProspects.InputDate
    FROM tblProspects
    WHERE (((tblProspects.CompName) Like [Forms]![frmMgtMain]![CompName]) AND ((tblProspects.AOName) Like [Forms]![frmMgtMain]![AOName]) AND ((tblProspects.GroupName) Like [Forms]![frmMgtMain]![GroupName]) AND ((tblProspects.Status)=[Forms]![frmMgtMain]![WillNot]))
    ...
    See more | Go to post

    Leave a comment:


  • Gari
    replied to Build a filter query with AND and OR statement
    Here are some examples:

    Let’s say I have those data (I did not take into account [CompName] and [GroupName] as the behaviour would be the same as [AOName]):

    [John Doe] [Not Contacted]
    [Emeveret Dupit] [Contacted]
    [Owen Solep] [Promised]
    [John Doe] [Will Not]
    [Emeveret Dupit] [Opened]
    [John Doe] [Not Contacted]
    [Emeveret Dupit] [Contacted]...
    See more | Go to post

    Leave a comment:


  • Gari
    replied to Build a filter query with AND and OR statement
    The behaviour of the program is like that:

    1. When you open the page, nothing is selected and all text boxes contain the "*" star. We thus expect all the data to appear. However, result is blank. Nothing at all appears.

    2. We can play with whatever criteria from [CompName], [AOName] & [GroupName] (the AND filter), no results at all are returned. For instance if we select a company name, still no results...
    See more | Go to post

    Leave a comment:


  • Gari
    replied to Build a filter query with AND and OR statement
    Hello,

    Thank you for the reply. Actually I already use the "*" as a default value for all the text boxes. The problem with my AND statements is that it is simply not working. Nothing happens, whereas for the OR stuff, it works dramatically well. Would it be of any use to build a nested query?
    See more | Go to post

    Leave a comment:


  • Gari
    started a topic Build a filter query with AND and OR statement

    Build a filter query with AND and OR statement

    Hello,

    I am trying to build a filter query with some AND and OR.

    I have three text boxes and 5 check boxes. The checkboxes are linked via code to other textboxes for the purpose of the query.

    The first three text boxes are:
    [CompName]
    [AOName]
    [GroupName]

    The other five text boxes are:
    [WillNot]
    [Contacted]
    [Promised]
    [Opened]
    [NotContacted]...
    See more | Go to post

  • Gari
    replied to Default Where criteria for Queries
    Hello,

    I have tried as you said but it does not work either.

    I feel that there is a problem of syntax in the code as when you build up the query in access, it puts by default an "=" into the code for the criteria field if nothing else is specified.

    So my original query (the one that does not work) looks like this:

    Code:
    SELECT tblProspects.CompName, tblProspects.Status
    FROM tblProspects
    ...
    See more | Go to post

    Leave a comment:


  • Gari
    replied to Default Where criteria for Queries
    Hello,

    First of all thanks for your reply.

    I have tried as you suggested the Dlookup inserted directly in the query.

    I have created a table called [Restrictions] with 2 fields: [ID], [Statusrestrict]. with one record as follows: [ID]= 1 and [Statusrestrict]=<>"AAA" And <>"BBB"

    In the query I call:

    Code:
    DLookup("[Statusrestrict]", "Restrictions",
    ...
    See more | Go to post

    Leave a comment:


  • Gari
    started a topic Default Where criteria for Queries

    Default Where criteria for Queries

    Hello,

    I am stuck with a problem here.

    I am building a database and I have several filter queries.

    In most of those queries I do a "Where" filter with always the same criteria, being something like:
    Code:
    <>"AAAA" And <>"BBBB"
    I may want to change this criteria later on.

    Is there any way to assign a constant value for this criteria...
    See more | Go to post

  • Gari
    replied to Textbox Data into a table
    Code:
    Dim SQL As String
    
    SQL = "Insert into tblMinutes(CompName, MinuteDate, MinuteText, NextVisit) values ( '" & Me.CompName & "', '" & Me.MinuteDate & "', '" & Me.MinuteText & "', '" & Me.NextVisit & "')"
    CurrentDb.Execute SQL
    This works.....

    Thank you.

    G.
    See more | Go to post

    Leave a comment:


  • Gari
    started a topic Textbox Data into a table

    Textbox Data into a table

    Hello,

    I have a table: tblMinutes
    With the fields: ID, CompName, MinuteDate, MinuteText, NextVisit

    I have a form: frmMinuteNew
    With the textbox: [CompName], [MinuteDate], [MinuteText], [NextVisit]
    All the textbox are UnBound EXCEPT the first one which is bound as follows: =Forms!frmProsp ectDisplayMain! CompName

    The Record Source for frmProspectDisp layMain is tblProspects. frmProspectDisp layMain...
    See more | Go to post

  • Gari
    replied to Save data from subforms to a table
    Thank you so much, it works amazingly!
    See more | Go to post

    Leave a comment:


  • Gari
    started a topic Save data from subforms to a table

    Save data from subforms to a table

    Hello,

    I have three subforms (let’s call them SFA, SFB, SFC) on one form (the reason there are subforms is that they are related to different queries).

    Each of these subforms contains a data (let’s call them SFA1, SFB2, SFB3).

    By clicking a button, I want to save SFA1, SFB2 and SFB3 in one table (this table is no related to the queries bound to SFA, SFB and SFC).

    Any idea how to do this?...
    See more | Go to post

  • Well… I took my time to answer because I faced problems with the form design… that I did not manage to do btw.

    Here is a picture of the form (attached).


    From top to bottom, the names of the labels are:

    Company Details_Title
    Company Name_Label
    Company_Account Number_Label
    Rating_Label
    Group Name_Label
    RM Name_Label
    Project Details_Title
    Owner Name_Label
    ...
    See more | Go to post

    Leave a comment:


  • Hello NeoPa,

    Sorry for the delay in answering you but I was away on holidays and did not have access to the internet. I came back to work today.

    I'll have a close look on your post and I'll post the form design later.

    Best regards,

    G.
    See more | Go to post

    Leave a comment:


  • Dear NeoPa,

    Thank you for your post.



    Actually all the value are not available in the form:
    - The only available value is [Account Number].
    - [Current Year] is the ... current year.... But I do not plan to put a Textbox for this. Actually, what I was thinking about is that the system will automatically input the current year.
    - Proj[Numbers of projects already created for this Account...
    See more | Go to post

    Leave a comment:


  • Hello NeoPa,

    Thank you for your answer. Actually I was refering to no threads in particular but I guess this one might help to understand:

    Button linking a continuous sub-form to a form (both built around several tables)

    My tables are all listed in there.

    Best regards,

    G.
    See more | Go to post

    Leave a comment:


  • Creating a Reference number that will serve as primary key

    Dear All,

    Back to my project database (if you have read my previous thread requests ^^).

    I have a project database.

    I will add an edit form that will be used to add new projects.

    I would like that when adding a new project; a reference is created for this one. This reference will be used as primary key.

    I want the reference to look like this:

    [Account Number]/[Current...
    See more | Go to post

  • Gari
    replied to Validate User password entry using VBA
    Most welcome and thank you for the answer about case sensitiveness.

    I have inserted those lines, being the best way I found to get rid of the problem. But I guess this is just a "trick". So, if someone knows a better way of coding that...

    Best regards,

    G.
    See more | Go to post

    Leave a comment:


  • Gari
    replied to Validate User password entry using VBA
    Re,

    I have resolved my issue by inserting those lines (bold):

    Code:
    Private Sub Login_Password_Click()
    
    [B]    If IsNull(txtPassword) Then
        txtPassword = "*"
        End If[/B]
    
        Dim strPW As String
    
        strPW = Nz(DLookup("Password", _
                           "tblUsername", _
                           "Username='" & Me.txtUsername
    ...
    See more | Go to post

    Leave a comment:


  • Gari
    replied to Validate User password entry using VBA
    Hello,

    I have used this code for implementing password on the access database I am building and it works well except for one situation:

    If I input a correct username, but I leave the password Textbox empty, it still performs the programmed action as if the username/password were correct and matching.

    How come ? Any Idea ?

    Thank you for your answer and best regards,

    G.
    See more | Go to post

    Leave a comment:

No activity results to display
Show More
Working...