Forums - C# Corner

Forum guidelines
Sandip Patil

Sandip Patil

  • 1.5k
  • 14
  • 627

Display Data in Table Format

Apr 15 2016 8:23 AM

I have Multiple Strings like


a:1:{s:10:"02-02-2015";a:13:{s:12:"control_room";s:14:"Control Room 1";s:8:"inverter";s:10:"Inverter 1";s:16:"daily_generation";s:4:"5225";s:9:"daily_plf";s:6:"21.77%";s:12:"grid_failure";s:8:"00:10:00";s:17:"force_maintenance";s:1:"0";s:9:"scheduled";s:1:"0";s:11:"unscheduled";s:1:"0";s:16:"generation_hours";s:8:"11:52:00";s:15:"operating_hours";s:8:"11:42:00";s:18:"plant_availability";s:7:"100.00%";s:17:"grid_availability";s:6:"99.00%";s:17:"breakdown_remarks";s:10:"No remarks";}}


a:1:{s:10:"02-02-2015";a:13:{s:12:"control_room";s:14:"Control Room 1";s:8:"inverter";s:10:"Inverter 1";s:16:"daily_generation";s:4:"5225";s:9:"daily_plf";s:6:"21.77%";s:12:"grid_failure";s:8:"00:10:00";s:17:"force_maintenance";s:1:"0";s:9:"scheduled";s:1:"0";s:11:"unscheduled";s:1:"0";s:16:"generation_hours";s:8:"11:52:00";s:15:"operating_hours";s:8:"11:42:00";s:18:"plant_availability";s:7:"100.00%";s:17:"grid_availability";s:6:"99.00%";s:17:"breakdown_remarks";s:10:"No remarks";}}


a:1:{s:10:"02-02-2015";a:13:{s:12:"control_room";s:14:"Control Room 1";s:8:"inverter";s:10:"Inverter 1";s:16:"daily_generation";s:4:"5225";s:9:"daily_plf";s:6:"21.77%";s:12:"grid_failure";s:8:"00:10:00";s:17:"force_maintenance";s:1:"0";s:9:"scheduled";s:1:"0";s:11:"unscheduled";s:1:"0";s:16:"generation_hours";s:8:"11:52:00";s:15:"operating_hours";s:8:"11:42:00";s:18:"plant_availability";s:7:"100.00%";s:17:"grid_availability";s:6:"99.00%";s:17:"breakdown_remarks";s:10:"No remarks";}}


Now to I Want to display Data Only Within "" string


Header and Values are in Same String for Ex

"02-02-2015" is a Date, "control_room" is Header and "Control Room 1" is the Values


Now i want to display in table format

Date

Control_room

Inverter

daily_generation

daily_plf

02-02-2015

Control Room 1

Inverter

5225

21.77%

03-02-2015

Control Room 1

Inverter

5225

21.77%

04-02-2015

Control Room 1

Inverter

5225

21.77%


How to Display This


Answers (6)