Search function

Graham Mackay

New Member
Joined
Apr 13, 2020
Messages
11
Office Version
  1. 2010
Platform
  1. Windows
Hi, I have a workbook that I am setting up to manage Permits. It has two active sheets. Register is the database and Index is the input function. Within Index I also have a search function which I want to search the register and display all the open Permits by searching column N and displaying any with Blank cells. I am struggling to get a macro to do this. Any help gratefully received
 
Hi Fluff,

Hopefully this is what you are looking for.
Permit To Work Register (3).xlsm
ABCDEFGHIJKLMNOPQ
1Permit NumberTask DescriptionPermit TypeLocationPermit Requested byPermit Issued ByPermit Issuer N°Date IssuedTime IssuedPermit ReceiverPermit Returned By Date ReturnedTime ReturnedDate CancelledTime CancelledPerson Cancelling PermitComments
283128698321901832190183219018321901832190183219018321901832190183219018321901832190183219018321901832190183219018321901
3 8218451832190183219018321901832190183219018321901832190183219018321901832190183219018321901832190183219018321901
4 8321041821845183219018321901832190183219018321901832190183219018321901832190183219018321901832190183219018321901
5 8132789821845182184518321901832190183219018321901832190183219018321901832190183219018321901832190183219018321901
6 8312869832104182184518218451832190183219018321901832190183219018321901832190183219018321901832190183219018321901
7  832104182184518218451821845183219018321901832190183219018321901832190183219018321901832190183219018321901
8  813278983210418218451821845182184518321901832190183219018321901832190183219018321901832190183219018321901
9  813278983210418218451821845182184518218451832190183219018321901832190183219018321901832190183219018321901
10  831286983210418321041821845182184518218451821845183219018321901832190183219018321901832190183219018321901
11   81327898321041821845182184518218451821845182184518321901832190183219018321901832190183219018321901
12   81327898321041832104182184518218451821845182184518218451832190183219018321901832190183219018321901
13   81327898321041832104182184518218451821845182184518218451821845183219018321901832190183219018321901
14   83128698132789832104183210418218451821845182184518218451821845182184518321901832190183219018321901
15    8132789832104183210418218451821845182184518218451821845182184518218451832190183219018321901
16    8132789832104183210418321041821845182184518218451821845182184518218451821845183219018321901
17    8132789813278983210418321041821845182184518218451821845182184518218451821845182184518321901
18 
Live Permits
Cell Formulas
RangeFormula
B2:Q17B2=IFERROR(INDEX(Register!$A$2:$A$1000,AGGREGATE(15,6,(ROW(Register!$A$2:$A$1000)-ROW(Register!$A$2)+1)/((Register!$A$2:$A$1000<>"")*(Register!$N$2:O$1000="")),ROWS(B$2:B2))),"")
A2:A17A2=IFERROR(INDEX(Register!$A$2:$A$1000,AGGREGATE(15,6,(ROW(Register!$A$2:$A$1000)-ROW(Register!$A$2)+1)/((Register!$A$2:$A$1000<>"")*(Register!N$2:$N$1000="")),ROWS(A$2:A2))),"")
A18A18=IFERROR(INDEX(Register!$A$2:$A$1000,AGGREGATE(15,6,(ROW(Register!$A$2:$A$1000)-ROW(Register!$A$2)+1)/((Register!$A$2:$A$1000<>"")*(Register!N$2:$N$1000="")),ROWS(A$3:A19))),"")
 
Upvote 0

Excel Facts

How to calculate loan payments in Excel?
Use the PMT function: =PMT(5%/12,60,-25000) is for a $25,000 loan, 5% annual interest, 60 month loan.
The formula in A2 should be
=IFERROR(INDEX(Register!A$2:A$1000,AGGREGATE(15,6,(ROW(Register!$A$2:$A$1000)-ROW(Register!$A$2)+1)/((Register!$A$2:$A$1000<>"")*(Register!$N$2:$N$1000="")),ROWS(A$2:A2))),"")

copied down & across
 
Upvote 0
The formula in A2 should be
=IFERROR(INDEX(Register!A$2:A$1000,AGGREGATE(15,6,(ROW(Register!$A$2:$A$1000)-ROW(Register!$A$2)+1)/((Register!$A$2:$A$1000<>"")*(Register!$N$2:$N$1000="")),ROWS(A$2:A2))),"")

copied down & across

Thanks you for that it seems to have dealt with the numbering issue but doesn't copy over text. The source information is below. Thank you for your patience as I am a total novice at this.
Permit To Work Register (3).xlsm
ABCDEFGHIJKLMNOPQ
1Permit NumberTask DescriptionPermit TypeLocationPermit Requested byPermit Issued ByPermit Issuer N°Date IssuedTime IssuedPermit ReceiverPermit Returned By Date ReturnedTime ReturnedDate CancelledTime CancelledPerson Cancelling PermitComments
28321901Tank CleaningSWPHJ BeggGA Mackay123456720/03/202010:2305/2/2020
38218451WeldingSTFM SutherlandGA Mackay1345678920/03/20209:20M Gunn2/6/2020
48321041weldingDWTFmeyou12345610/2/201810:55him3/6/2020
58132789Tank CleaningMAXWELL HOUSEYouMe12345617/03/202012:45Him2/10/2020
6831286965465463541uiygukyg654654654654654654546546546546.54655E+11
7tank cleaning
8
9
Register
 
Upvote 0
Upvote 0
That;s exactly what I would expect to see from the data you posted.
In what way is it wrong?
 
Upvote 0
Sorry, I was expecting to see the text, example in column B in the source worksheet there is a task description in text but this is displayed as a zero in the second worksheet. as is the remaining columns with text.
 
Upvote 0
There is no text in col B for that permit number, the only data for that row is in cols K:M & O:Q
 
Upvote 0
I apologise, yes I forgot I had entered dates in column N. This works perfectly. Thank you so much for taking the time to resolve this for me. I am very grateful.

Kind Regards and Stay Say
Graham
 
Upvote 0
You're welcome & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,214,643
Messages
6,120,707
Members
448,981
Latest member
recon11bucks

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top