Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

Troubleshooting
Research
Professional Opinions
Ask a Question
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE

troubleshooting Question

Displaying Child Forms, ADO,Access,Depending on Multiple Paramaters..

Avatar of Grant Fullen
Grant Fullen asked on
Delphi
18 Comments1 Solution279 ViewsLast Modified:
I have an access database named clean.mdb. A table nemed PostJob.
Fields in table is.....
JobName / Text
JobWorkers / Text
JobPrice / currency
JobTax / Curency
JobTotal / Currency
Daily  / True/False
Weekly  True/False
BIWeekly True/False
Available True/False
Monthley True/False
Recurring True/False . I only need to display .
I am createing Child Forms with treeviews in them. I am displaying the JobName , and JobWorkers in the treeview.
<<<<<<<<<<<<<<<< Code Below>>>>>>>>>>>>>>>>>>.
with DataModule2.PostJobQuery do
  begin

    Open;
    while not eof do
    begin
      sl:= TStringList.Create;


      JobStr:= DataModule2.PostJobQuery.FieldByName('JobName').AsString;
      WorkerStr:= DataModule2.PostJobQuery.FieldByName('JobWorkers').AsString;

      CreateChildForm(JobStr);
      Tile;
      Root1 := TFrmTreeView(Main.ActiveMDIChild).TreeView1.Items.Add(nil, 'Job Description');
      Child1:= TFrmTreeView(Main.ActiveMDIChild).TreeView1.Items.AddChild(Root1, JobStr);

      Root2 := TFrmTreeView(Main.ActiveMDIChild).TreeView1.Items.Add(nil, 'Workers');
      sl.CommaText:= WorkerStr;
      for i2:= 0 to sl.Count -1 do
        Child2:= TFrmTreeView(Main.ActiveMDIChild).TreeView1.Items.AddChild(Root2, sl.Strings[i2]);
      inc(i);
      DataModule2.PostJobQuery.Next;
    end;
    sl.Free;
    Close;
  end;
  end;
Problem. I onlly need to disply these feilds if Available and Recurring are true. I need some sample code with the proper SQL statements.
Thanks
Grant
ASKER CERTIFIED SOLUTION
Avatar of danielluyo
danielluyo

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Commented:
This problem has been solved!
Unlock 1 Answer and 18 Comments.
See Answers