Embedded system 16x2 lcd user interface
You have not mentioned which MCU you are using but looking at the tag I am assuming you are using PIC MCU. The best solution for your problem is to use FreeRTOS. FreeRTOS is available for PIC18 PIC24 PIC32. You can easily create as many task you want and can also include while(1) inside them. 

xTaskCreate( vTask1, "Task 1", 240, NULL, 1, NULL );
xTaskCreate( vTask2, "Task 2", 240, NULL, 1, NULL );
xTaskCreate( vTask3, "Task 3", 240, NULL, 1, NULL );

void vTask1()
{
 for(;;)
 {
    PORTDbits.RD0 = 1;
    vTaskDelay( 1000 / portTICK_RATE_MS );
    PORTDbits.RD0 = 0;
    vTaskDelay( 1000 / portTICK_RATE_MS );

 }
}


same you can do for other task. Now all you need to do is run scheduler

vTaskStartScheduler();