I wish to create a Search bar which will return very specific values from a GSheet

You have this variable
image
which can be accessed from any screen in the app.

You are using it to hold the data values in the selected row

So you can, in any screen, display the data values of this row in the same way you are displaying it now in the search screen
image
Instead of the labels of this screen you can display the values to any label / text input in any other screen.

Thanks @muneer, I sort of understand but I were to recreate my Search screen from MANFVScreen onto my MANFVEntScreen, would I then be able to edit/ update the data and add new/ remove records on this screen? (My MANFVEntScreen that is).
Thanks,

Andos.

1 Like

Yes you can. Just use the appropriate Data Source block along with the app variable that holds the row data values in case of update. You will also need to store the row number or (row ID) so you can update the selected row.

Ok thanks @muneer, I am still not very sure but I shall try to have a go at this. I will let you know how I get on with it. Would those Data Source blocks be the purple ones? I really don’t understand the use/ concept of “row id” ( fingers crossed ).

Thanks,

Andos.

1 Like

Ok @muneer, I have now duplicated my MANFVScreen onto my MANFVEntScreen. Would I replace the Labels 1-7 blocks with text input blocks so that they can be edited?

It seems to be the only thing I can think of to resolve amend/update issue. If this is the case how do I create a “Submit” action to enter the new or updated data into my Google Sheet?

Thanks,

Andos.

1 Like

I have updated the demo project to show the edit screen. The add new is empty but I wanted to show the edit screen and the use of the blocks so it becomes clear to you.

https://x.thunkable.com/projectPage/61ca295782be4c01a096dab0

1 Like

Thanks @muneer, I shall look at it when I get home

Thanks,

Andos.

1 Like

Hi @muneer, many thanks for your suggestion. The idea looks very good. I have copied your blocks into my project but have found that there are now no results showing on the “MANFVSearch” after an item has been clicked. Please see image below:

I added Label Visible blocks set to “true” to resolve this. Was this correct? See below:

I created a “D-UMMY” record directly into my Source Data Google Sheet (MAN First Visits) in the “FVENTRYFORM” tab. (see below) so that I could try editing the “D-UMMY” record.

It worked beautifully :slightly_smiling_face: :+1:

…until I added the " Label Visible blocks set to “true” " for some reason… :frowning_face:

How do I create a confirmation message to notify the user that the record has been successfully or unsuccessfully entered into, or removed from the Google Sheet?

To create the New Entry Screen would I just copy the Edit Screen into the MANFVEdit screen into the New Entry Screen?

Also, how do I allow the user to delete an entry without leaving empty rows in my Source Data Google Sheet?

Thanks,

Andos.

1 Like

This is dependent on your coding. In my example, I was setting visibility of row1 & row2 to true/false. Those rows are containing all the labels instead of setting each label separately.

[Edit]
See that I make sure the two rows are hidden
image

When the user selects a record from the list, I made them show at the end of the process of assigning the values to the labels
image

See the design
image

Hi @muneer, yes that was how I had blocks set up. ( The same as your sample images). But for some reason, that didn’t work . All good with that issue now. Many thanks.

I have some more questions…

  1. My entries made on my “FVEditScreen” are no longer updating into my Data Source Google Sheet (MAN First Visits). It worked once then stopped. What would cause this?

  2. How do I create a confirmation message to notify the user that the record has been successfully or unsuccessfully entered into, or removed from the Google Sheet?

  3. To create the New Entry Screen would I just copy the Edit Screen into the MANFVEdit screen into the New Entry Screen?

  4. Also, how do I allow the user to delete an entry without leaving empty rows in my Source Data Google Sheet?

Thanks,

Andos.

1 Like

Need more info.

One way is to do something similar to this idea

You can also use the Alert component to display a message.

Just design your own and when saving the data use create row block to save the values to the sheet
image

The delete block will take care of that.
image

Hi @muneer,

[quote=“muneer, post:51, topic:1647137”]

Need more info.

as in my previous image in my previous post I created a “D-UMMY” record which I typed directly into my “MAN First Visits” “FVENTRYFORM” tab of my Data Source Google Sheet and then from my project app I tried editing on the “FVEditScreen” in the “Live Test” mode. It worked perfectly on the first try. But, when I tried to edit it again a little while later, it would not update after I had modified “Label Visibility

The FVEditScreen would allow me to enter data as expected but when I clicked the “Save” button nothing happens. (See below:)

When I check my Source Data Google Sheet “FVENTRYFORM” the update in the “D-UMMY” record, nothing has changed. See below:

I can’t see how changing my Label blocks’ visibility would affect this so I suspect the error must elsewhere. :worried:

=========================================================================

One way is to do something similar to this idea

Would I have to use all of those blocks for each label?

Also, in the create row block against “REG value”; “C/N value” etc… would I have to use the “AddRecText_InputREG’S/Text” component; “AddRecText_InputREG/Text” component etc… in the “Create Row” block as I’ve shown below?

…and what do I put in the “Create Row” block’s “Do” space?

I will ask about the “delete row” block when I get to it.

Many thanks,

Andos.

1 Like

Can you explain why are you searching on “FV” Google sheet tab and then want to update a different tab. Each tab in the Google sheet file is concerned a separate data source and are not related to each other.

Hi @muneer, the reason for this is the “FV” Google Sheet is used for my website and the data is automatically and capitalized from the data entered into the “FVENTRYFORM” Google Sheet. No data can be directly entered into “F/V” Google Sheet because of all the formulas. The only way to enter data into the “FV” Google Sheet is via the “FVENTRYFORM” Google Sheet.

Because the “FV” Google Sheet is in an organised format that is the Google Sheet I wish to display as some the entries into the “FVENTRYFORM” Google Sheet are a mixture of upper and lower and would look very messy if displayed.

I hope this helps.

=============================================================================

I also have noticed that all of the Input Label displaying a value of “null” instead of displaying the “hints” as laid out on the Design Page. Do you know why this is so? (See below)

Live Test View

Design View

Many thanks,

Andos.

1 Like

Hi @muneer, I have just tried your above suggestion for the “Saved Status” message but it doesn’t seem to work. Is this because the edit page doesn’t seem to be doing anything?

Here is a view of my blocks:

Can you see anything wrong with them?

Many thanks,

Andos.

1 Like

This will make things very difficult. We will not be able to know why changes are not taking place. Do we blame Thunkable or Google sheet formulas?

This means you are using the wrong row_number and again because you are taking the row_number from one tab in the Google sheet and should be used to refer to another tab. It can work and it can break.

Hi @muneer, could all this then be resolved by using the “FVENTRYFORM” Source Data on the Google Sheet instead of “FV”?

Thanks,

Andos.

1 Like

Hi @muneer, I have been painstakingly going the “FV” Data Source on the Google Sheet and found there were only a handful of entries in “lowercase” format. So I think I will change all sources to “FVENTRYFORM” to see if that helps.

Many thanks,

Andos.

I would have no idea at all. You are the owner of the data not me. To me these are rows and rows of values.

I will take the following approach to this issue. Again, this is just a suggestion and there could be many others

When starting the screen I will set a control variable to empty
image

Whenever any of the fields changes and needs to be saved/update I will also update the control variable with the column name.
image

I would then check if the control variable contains any column and will read the updated record and test if the changes has taken place.
image

Hi @muneer, I think I understand this method ( :crossed_fingers:).

You were right!! :+1: :+1: :+1:

I have changed all the Google Sheet Data Sources to “FVENTRYFORM” (- which means they are all using the same source) and the update entries are now working!! :slightly_smiling_face: :+1:

But the confirmation messages weren’t working. So I have used your latest solution and now it all works as intended except for the presence of all of the Input Labels displaying a value of “null ” instead of displaying the “hints ” as laid out on the Design Page .

Then I just have the Delete functions and the Add New Entry screen to tackle :worried: :worried: :sweat_smile: :sweat_smile: :wink:

Once again many thanks!

Andos.

1 Like