Topic: Please help!!!!

[Hello All,

I'm a newbie and need help with the following issue:... I want to be able to pass data between forms to enter on a textbox.  Example: When I have form1 open, I enter text in a textboxfield, then I press a button on form1 and it opens form2 and displays the text I entered on form1 in an empty textbox on form2.  Is this possible?   Here's a graphic of what I want done in VB:


Attached.

http://i63.tinypic.com/15wf4e9.jpg

Thanks in advance!!

Post's attachments

Attachment icon PassData.jpg 12.3 kb, 265 downloads since 2017-02-23 

Re: Please help!!!!

Here is an example. See attached.

Post's attachments

Attachment icon PassData.zip 579.35 kb, 472 downloads since 2017-02-23 

Re: Please help!!!!

ehwagner wrote:

Here is an example. See attached.

Thank you so much man!  that worked like a charm!!  smile

Re: Please help!!!!

One more thing @ehwagner... what if I wanted to do the same exact thing but with a picture?  If I have a picture that shows on
suppose, form1 that I loaded from the database, how do I get it to show on form2 when I press a button on form1?   Is that
possible?  thank you in advance!

Re: Please help!!!!

Hello Gonpublic, EH,
Welcome to MVD.
Yes, you can do exactly the same thing with photos (and pretty much everything else).
Please see attached for some options (in MVD there are always many ways to do things).
Hope this helps,
Derek.

Post's attachments

Attachment icon PassData.zip 1.39 mb, 448 downloads since 2017-02-24 

Re: Please help!!!!

Okie!  big_smile   Thanks Derek, will post my results.

Re: Please help!!!!

Gonpublic & Derek,
Derek was spot on. I made a slight mod. Derek's picture may not have shown up on your form because it was located on his computer. I made an image folder within the project and placed a picture there to show you the results.

Post's attachments

Attachment icon PassData2.zip 601.04 kb, 472 downloads since 2017-02-24 

Re: Please help!!!!

Thanks to all of you, yes ehwagner, I did see that and fixed it in my project.  Thanks.  Everything is working fine, another question
how do you display in a datagrid only certain columns, say based on user profile?   i.e.  If I have two users that access the database,
one with administrator privileges to the database and another with only view privileges ( I created a login form for this ) how do I enable
only certain columns to show in the datagrid for the user without administrative privileges?  I know it's a bit confusing, sorry for the long
sentences.. sad

Appreciate your help!

Re: Please help!!!!

gonpublic2k wrote:

Thanks to all of you, yes ehwagner, I did see that and fixed it in my project.  Thanks.  Everything is working fine, another question
how do you display in a datagrid only certain columns, say based on user profile?   i.e.  If I have two users that access the database,
one with administrator privileges to the database and another with only view privileges ( I created a login form for this ) how do I enable
only certain columns to show in the datagrid for the user without administrative privileges?  I know it's a bit confusing, sorry for the long
sentences.. sad

Appreciate your help!

Still need help with this, please sad    yikes

Re: Please help!!!!

Example, how to hide some columns in a TableGrid

procedure Form1_TableGrid1_OnChange (Sender: string);
begin
    Form1.TableGrid1.Columns[0].Visible := False;
    Form1.TableGrid1.Columns[2].Visible := False;
end;
Dmitry.

Re: Please help!!!!

Hi Gonpublic, EHW,
Attached is one approach you could take (there are lots of others - but this keeps it pretty basic).  It uses different tablegrids - one showing all columns and allowing maintenance, the other showing limited columns and display only;  which tablegrid you see is dependant on your level of access (determined by your password).
The current passwords to gain access are 'DEREK' (for full access) and '12345' (for restricted access).  However, if it's the first time the app is run, security is by-passed and takes you straight to a password set-up screen where your first entry must be a password with FULL access;  if you wanted to check this out, simply delete the sqlite.db file and run it as if it was the first time.
Hope it helps,
Derek.

Post's attachments

Attachment icon gonpublicaccess.zip 439.19 kb, 477 downloads since 2017-03-01 

Re: Please help!!!!

Thank you all for your kind replies, I'm learning a lot with the examples.  Much appreciated smile