Excel - Using jSON file in excel with customization

Copper Contributor

Hi All, In my one of the project, I need to use jSON file in excel in following manner so that I can tie up its columns with excel data.

For example  -  In my workbook there is a TAB like this ..

TheTallman_0-1625396860724.png

I want that User should be able to choose a particular json file from browse button in excel

TheTallman_1-1625396883533.png

 

And that file should be highlighted here like in yellow

once he picks , particular json file should be load in sql table. In sql table, it will be stored like this ..

(Pls confirm if i can load this same in excel without using sql interface.)

TheTallman_2-1625396910981.png

 

In excel, there is column which value matches with Label so excel through validate button should match each and every entry and put value from hidden column next to it like this ..

 

TheTallman_3-1625396933003.png

Kindly help me how I can do this through VBA/MACROS.

 

4 Replies

@TheTallman Seems to be more appropriate to use Power Query for this. Query and parse the selected JSON file and query your Excel table. Then merge them and load back into Excel. Exactly how? That depends on your real files, and my guess is that it's going to easier than with VBA. Are you familiar with Power Query?

Thanks @Riny_van_Eekelen ! I'm not familiar with Power Query and also I'm making it for end user so can we make it automate in same way as i defined .

@TheTallman Can't answer that question if you don't upload realistic examples of your files, but I believe it can be made in a way that is similar to what you require.

 

@Riny_van_Eekelen I uploaded sample files. can you please help how i can move forward with discussed approach.