| 
			
			 | 
		#1 | 
| 
			
			
			
			 Custom User Title 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,359 
				Karma: 79528341 
				Join Date: Oct 2018 
				Location: Canada 
				
				
				Device: Kobo Libra H2O, formerly Aura HD 
				
				
				 | 
	
	
	
		
		
			
			 
				
				Combining multiple "fewer days ago then" colour rules
			 
			
			
			I have these three rules: 
		
	
		
		
			It's intended to make it easier to know at a glance which of my "recently updated fanfics" (>7daysago) is the newest: To make it easier to apply to other columns, how would I combine this into a single advanced rule while keeping the order of precedence? Thank you!  | 
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#2 | 
| 
			
			
			
			 Grand Sorcerer 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 12,525 
				Karma: 8065948 
				Join Date: Jan 2010 
				Location: Notts, England 
				
				
				Device: Kobo Libra 2 
				
				
				 | 
	
	
	
		
		
		
		
		 
			
			Wait for the next release, then: 
		
	
		
		
		
		
		
		
		
		
		
		
	
	
 Code: 
	program:
test(and(
         strcmp(field('#enum2'), "no", '', '1', ''),
         strcmp(field('#enum3'), "no", '', '1', '')
    ), 'cry-icon.png', '');
Code: 
	program:
first_non_empty(
    test(and(
         strcmp(field('#enum2'), "no", '', '1', ''),
         strcmp(field('#enum3'), "no", '', '1', '')
    ), 'cry-icon.png', '')
)
Code: 
	program:
first_non_empty(
    test(and(
         strcmp(field('#enum2'), "no", '', '1', ''),
         strcmp(field('#enum3'), "no", '', '1', '')
    ), 'cry-icon.png', ''),
    test(and(
         strcmp(field('#bar'), "no", '', '1', ''),
         strcmp(field('#flapjack'), "no", '', '1', '')
    ), 'foo.png', '')
)
 | 
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| Advert | |
| 
         | 
    
| 
			
			 | 
		#3 | 
| 
			
			
			
			 Custom User Title 
			
			![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,359 
				Karma: 79528341 
				Join Date: Oct 2018 
				Location: Canada 
				
				
				Device: Kobo Libra H2O, formerly Aura HD 
				
				
				 | 
	
	
	
		
		
		
		
		 
			
			Thanks for implementing the 'convert to advanced rules' for next release, btw  
		
	
		
		
		
		
		
		
		
		
		
		
		
			  I learn a bit better by seeing examples.
		Last edited by ownedbycats; 12-20-2020 at 08:26 PM.  | 
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
![]()  | 
            
        
    
            
  | 
    
			 
			Similar Threads
		 | 
	||||
| Thread | Thread Starter | Forum | Replies | Last Post | 
| Calibre-generated epub (from .docx) gives "e21027" "multiple opf files" on KindleGen | GhostRider | Conversion | 2 | 08-28-2024 11:14 AM | 
| Add "font-size" and "font-colour" functions to next version of Page Edit? | hhtmp88 | Sigil | 6 | 08-20-2020 04:09 PM | 
| hierarchy feature using rough "Dewey number" instead of "genre" - multiple DDCs? | kite | Library Management | 4 | 10-13-2014 10:53 AM | 
| "Multitasking Moms Endorse The KOBO VOX Colour eReader" | scrapking | Kobo Tablets | 0 | 03-16-2012 01:33 PM | 
| "Stretching crystals promises flexible colour displays" | jharker | News | 13 | 09-05-2007 01:03 PM |