Solved

Passing string data from form to form.

Posted on 1997-06-17
6
130 Views
Last Modified: 2010-04-04
How can I pass data in a string variable across forms without the new form nulling the variable?
0
Comment
Question by:the2x4
  • 4
6 Comments
 
LVL 4

Expert Comment

by:erajoj
ID: 1337114
Huh?
Please explain further.

/// John

0
 
LVL 4

Accepted Solution

by:
StevenB earned 50 total points
ID: 1337115
 I think what John was getting at was that you havn't provided enough information for a good answer to be provided. From what you've written it seems as though there should be no problem. Passing a string variable from one unit/form to another can be done simply by referencing the other unit in the assign statement and making sure the unit is in the uses clause:

{In Form1}

var
  AString : String;

{In Form2}

Uses
  Form1;

......

var
  AnotherString : String;
begin
  AnotherString := 'Some piece of information vital to Form1';
  Form1.AString := AnotherString;
end;

  This seems to be what your asking, but if I've completely missed the point then you'll have to explain the problem more fully, perhaps with some code.

  Steven.
0
 

Author Comment

by:the2x4
ID: 1337116
I recently bought Delphi 3 with no experience at all in that
language. I knew the learning curve would be steep but 3 was
reccomended for its fast app developement. It indeed is quicker
for me. I resolved the problem another way still the original
question explains the results I obtained. I am sure the reference
Steven explained is the solution. Delphi 3 would be a snap if I
had been thru 1 & 2. Thank you Stephen for assuming I needed
BASIC :-) assistance. Thanks for the help.
0
What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

 
LVL 4

Expert Comment

by:StevenB
ID: 1337117
 You should have no difficulty in learning into Delphi 3 without having used 1 or 2. Glad to have helped.

  Steven.
0
 
LVL 4

Expert Comment

by:StevenB
ID: 1337118
 You should have no difficulty in learning Delphi 3 without having used 1 or 2. Glad to have helped.

  Steven.
0
 
LVL 4

Expert Comment

by:StevenB
ID: 1337119
 I hate it when that happens.
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
Objective: - This article will help user in how to convert their numeric value become words. How to use 1. You can copy this code in your Unit as function 2. than you can perform your function by type this code The Code   (CODE) The Im…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now