global connection variable

how to change the global connection when i click on dynamic menu link by passing a connection variable to the application.

If I understood correctly, sc_connection_edit macro is what you are looking for.