we have done all the configurations required and USB as 48Mhz and application is getting started but its not active to create the text file. What may be the issue?
And you can find examples in STM32 repository installed with STM32CubeMX packages on your PC. Please look for STM32Cube\Repository folder and MSC_Standalone demo project.