Return only whole numbers

riedyp

Board Regular
Joined
Feb 13, 2020
Messages
88
Office Version
  1. 365
Platform
  1. Windows
Hello ,
I am trying to make a condensed table(White picture Circled in Red) from returning values in another table(Yellow table). I only want to return the whole numbers without leaving blank spaces. I am currently trying to find the best way to do this. I do not know if its possible to do without VBA. My current method is using the INT function in Column A of the "Yellow picture" to see if column A and B match and then want to return the value of the match to my other table(White Picture" circled in Red) without any spaces between numbers being seen.
 

Attachments

  • forum2.PNG
    forum2.PNG
    34.2 KB · Views: 17
  • forum3.PNG
    forum3.PNG
    18.8 KB · Views: 17

Excel Facts

How to change case of text in Excel?
Use =UPPER() for upper case, =LOWER() for lower case, and =PROPER() for proper case. PROPER won't capitalize second c in Mccartney
Could you explain this further, please? I understand the column A and B point, and do not believe that you even need a separate column A, but what is your expectation? The yellow table doesn't show anything in the Hrs Allocated column (col. E), yet for Phase 1 in the white table, 8 hours are shown...same issue for the Hours Spent column, where the yellow table indicates 90 hours for Task 1 and the white table shows only 7. Is your intention to sum all of the hours allocated and spent for each phase (meaning all of the tasks under each phase)? Isn't that already shown in the yellow table where subtotals appear for each phase?
 
Upvote 0
I will also want to return the "Hrs. Allocated" and "Hrs Spent" into that "white table circled red" as well. My intention is to make my "white table circled red" to summarize the "Yellow table" that will be filled out. Meanwhile the "white table circled red" will be locked and unable to be edited. So yes, you were understanding that for the most part.
 
Upvote 0
I'm not sure if this is what you have in mind, but have a look at this. There are two sheets: ProjectTasks and ProjectSummary. The ProjectSummary sheet examines column B of the ProjectTask sheet to determine how many main level phases there are, and then it creates a list of those phases (like the 1, 2, and 3 in your white table). Then those phase numbers (in column A of the ProjectSummary worksheet are used with INDEX/MATCH formulas to pull the relevant information from the ProjectTasks worksheet. All of the subtotal work is still done on the ProjectTask worksheet.

Book1c.xlsx
ABCDEFGHI
1PhaseTasksWhoHrs AllocHrs SpentStartEnd%Complete
21Planning809090%
31.1Task 1810
41.2Task 21215
51.3Task 36065
62Dev't877940%
72.1Task 11215
82.2Task 24034
92.3Task 33530
103Test908330%
113.1Task 1108
123.2Task 23035
133.3Task 35040
ProjectTasks
Cell Formulas
RangeFormula
E10:F10,E6:F6,E2:F2E2=SUBTOTAL(9,E3:E5)


Book1c.xlsx
ABCD
14Phase #Hours AllocatedHours SpentStatus
151809090%
162877940%
173908330%
18    
19    
20    
21    
22    
ProjectSummary
Cell Formulas
RangeFormula
A15:A22A15=IF(ROW()-ROW(A$14)<=SUMPRODUCT(--(ProjectTasks!$B$2:$B$13=INT(ProjectTasks!$B$2:$B$13))),ROW()-ROW(A$14),"")
B15:B22B15=IFERROR(INDEX(ProjectTasks!$B$2:$I$13,MATCH($A15,ProjectTasks!$B$2:$B$13,0),4),"")
C15:C22C15=IFERROR(INDEX(ProjectTasks!$B$2:$I$13,MATCH($A15,ProjectTasks!$B$2:$B$13,0),5),"")
D15:D22D15=IFERROR(INDEX(ProjectTasks!$B$2:$I$13,MATCH($A15,ProjectTasks!$B$2:$B$13,0),8),"")
 
Upvote 0
Hi Kirk,
Having some trouble with this, below is what i inputted. I am wondering where i am going wrong with this. thank you
K33=IF(ROW()-ROW(A$32)<=SUMPRODUCT(--('Project - Gantt Chart'!$D$9:$D$45 =INT('Project - Gantt Chart'!$D$9:$D$45))),ROW()-ROW(A$32),"")
L33= IFERROR(INDEX('Project - Gantt Chart'!$D$9:$K$45,MATCH('Executive Summary'!$K33,'Project - Gantt Chart'!$D$9:$K$45,0),4),"")
M33=IFERROR(INDEX('Project - Gantt Chart'!$D$9:$K$45,MATCH('Executive Summary'!$K33,'Project - Gantt Chart'!$D$9:$K$45,0),5),"")
N33=IFERROR(INDEX('Project - Gantt Chart'!$D$9:$K$45,MATCH('Executive Summary'!$K33,'Project - Gantt Chart'!$D$9:$K$45,0),8),"")
 
Upvote 0
'Project - Gantt Chart'!$D$9:$K$45 should refer to your block of data on the "Project - Gantt Chart" worksheet. If that is correct, then columns D through K represent 8 columns. Can you confirm that you want data returned from the 4th, 5th, and 8th columns (i.e., columns, G, H, and K)?

Did you copy the formula in K33 down into X number or more cells so that the 1st column references can be generated...where X is greater than or equal to the number of main phases on the other sheet?

You can use the XL2BB tool (see links in my signature line or elsewhere on this post) for copying a small portion of your worksheet and uploading it.
 
Upvote 0
What did cells K33, L33, M33, and N33 display after you entered those formulas?
 
Upvote 0
apologies for the confusion i was trying something else but here is my current tables . And yes Phase #'s do show up but that is about it.
With the updated formulas:

K33=IF(ROW()-ROW(A$32)<=SUMPRODUCT(--('Project - Gantt Chart'!$B$9:$B$45 =INT('Project - Gantt Chart'!$B$9:$B$45))),ROW()-ROW(A$32),"")
L33=IFERROR(INDEX('Project - Gantt Chart'!$B$9:$I$45,MATCH('Executive Summary'!$K33,'Project - Gantt Chart'!$B$9:$I$45,0),4),"")
M33=IFERROR(INDEX('Project - Gantt Chart'!$B$9:$I$45,MATCH('Executive Summary'!$K33,'Project - Gantt Chart'!$B$9:$I$45,0),5),"")
N33=IFERROR(INDEX('Project - Gantt Chart'!$B$9:$I$45,MATCH('Executive Summary'!$K33,'Project - Gantt Chart'!$B$9:$I$45,0),8),"")


Picture "forum 7" is what happens when i pull down the formula.
 

Attachments

  • forum5.PNG
    forum5.PNG
    38.8 KB · Views: 4
  • forum6.PNG
    forum6.PNG
    8.4 KB · Views: 4
  • forum7.PNG
    forum7.PNG
    9.4 KB · Views: 4
Upvote 0
Try these:

K33=IF(ROW()-ROW(K$32)<=SUMPRODUCT(--('Project - Gantt Chart'!$B$9:$B$45 =INT('Project - Gantt Chart'!$B$9:$B$45))),ROW()-ROW(K$32),"")
L33=IFERROR(INDEX('Project - Gantt Chart'!$B$9:$I$45,MATCH('Executive Summary'!$K33,'Project - Gantt Chart'!$B$9:$B$45,0),4),"")
M33=IFERROR(INDEX('Project - Gantt Chart'!$B$9:$I$45,MATCH('Executive Summary'!$K33,'Project - Gantt Chart'!$B$9:$B$45,0),5),"")
N33=IFERROR(INDEX('Project - Gantt Chart'!$B$9:$I$45,MATCH('Executive Summary'!$K33,'Project - Gantt Chart'!$B$9:$B$45,0),8),"")

You had some issues with your MATCH reference...you want to match the value in column B of the Project-Gantt Chart. Copy all of these across row 33 and then copy down into rows below.
 
Upvote 0
Thank you so much. I should have seen that mistake. Is there anyway for me to format it so that if there are no values for phase 4 then it will not show the number 4? and if there are values in 4 then it will?
 

Attachments

  • forum9.PNG
    forum9.PNG
    6.3 KB · Views: 4
Upvote 0

Forum statistics

Threads
1,223,912
Messages
6,175,348
Members
452,638
Latest member
Oluwabukunmi

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