Passing Date-Picker information (startDate and endDate) as a variables in the URL to fetch filtered data from thingspeak

Hi,
When I use the actual datetime values in the url, I get the expected results, but when i try to store these values in a global variable and pass those variables in the url, I am getting complete results rather than the filtered results based on the selected start and end date. Below are the url used:
https://api.thingspeak.com/channels/2505468/fields/5.json?api_key=25ZJKZEKJ2PIE89Q&start=2024-04-01%2000:00:00&end=2024-04-02%2023:59:59

https://api.thingspeak.com/channels/2505468/fields/5.json?api_key=25ZJKZEKJ2PIE89Q&start=&globalstartDate&&end=&globalendDate

I have tried multiple options like using double quotes,single quotes to pass the global variables the URL but no luck..

use Do it to debug your blocks, see also tip 4 here App Inventor: How to Learn | Pura Vida Apps
see also Live Development, Testing, and Debugging Tools

It would really help if you provided a screenshot of your relevant blocks, so we can see what you are trying to do, and where the problem may be.

To get an image of your blocks, right click in the Blocks Editor and select "Download Blocks as Image". You might want to use an image editor to crop etc. if required. Then post it here in the community.

Taifun


Trying to push the limits! Snippets, Tutorials and Extensions from Pura Vida Apps by icon24 Taifun.

Here is a Thingspeak sample:

If that does not help,
(Canned Reply: ABG- Export & Upload .aia)
Export your .aia file and upload it here.

export_and_upload_aia

.

.aia file for reference
SolarPower (1).aia (24.4 KB)