Excel问题 – 选择下一次

huangapple go评论63阅读模式
英文:

Excel issue - choose next time

问题

下午好,

我在努力解决我试图解决的问题。
基本上,我有一个包含时间值的列表。
看一个例子:

Excel问题 – 选择下一次

正如您所见,时间值有时可能在相同的时间间隔内。

这是我希望最终结果看起来的方式:

Excel问题 – 选择下一次

我使用以下公式在下一个工作表中显示开始和结束结果。

=IF(WTW!D4="", "", LEFT(TEXT(WTW!D4, "HH"), 2)&":00")

我如何才能实现最终结果仅显示开始时间和结束时间,而不重复显示结束结果。

例如:
不好的最终结果
06:00 - 07:00
06:00 - 07:00

好的结果
06:00 - 07:00
07:00 - 08:00

这一切的原因是因为开始和结束时间可以更改...

英文:

Good afternoon,

I am struggling to fix the issue I'm trying to resolve.
Basically, I have a list which includes time values.
See example:

Excel问题 – 选择下一次

As you can see the time values could sometimes be in the same time interval.

That's how I would like it to look at the end result :

Excel问题 – 选择下一次

I'm using the following formula to display the start and end result in the next sheet.

=IF(WTW!D4="","",LEFT(TEXT(WTW!D4,"HH"),2)&":00")

How I could achieve that the end result to basically only display the start and end time without duplicating the end results.

As example:
Bad end result
06:00 - 07:00
06:00 - 07:00

Good result
06:00 - 07:00
07:00 - 08:00

The reason for all this is because the start and end hours can change...

答案1

得分: 1

=IFERROR(INDEX(Sheet3!$B$3:$B$30, MATCH(0, COUNTIF($Q$1:Q2,Sheet3!$B$3:$B$30), 0)), "")

只需要在整个列表中插入某种方式,以便这也过滤一个额外的条件...

英文:

I've managed to sort the unique time by the following formula:

=IFERROR(INDEX(Sheet3!$B$3:$B$30, MATCH(0, COUNTIF($Q$1:Q2,Sheet3!$B$3:$B$30), 0)), "")

Just now need to insert somehow so that this also filter one extra criteria in the whole list...

答案2

得分: 0

=TIME(HOUR(A1),0,0)

然后右键单击所选单元格/区域,点击格式单元格。点击自定义,将文本框替换为hh:mm

英文:

Hour function may not be insufficent. Why don't you try:

=TIME(HOUR(A1),0,0)

Than right click at the selected cell/range and click Format Cells. Click Custom and replace textbox to hh:mm

huangapple
  • 本文由 发表于 2023年3月9日 23:11:45
  • 转载请务必保留本文链接:https://go.coder-hub.com/75686505.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定