Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

using text object value from crystal report into formula editor

Posted on 2004-09-08
8
Medium Priority
?
3,141 Views
Last Modified: 2012-06-22
i have a text box object in my crystal report form,(named txtName) and i've assign a value to it...let say "My Name". I want to create a formulae that used the text box value....like, "I want to print this" & txtName.value, but this method won't work..:D please somebody help me..;D
0
Comment
Question by:craduza
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
  • 2
8 Comments
 
LVL 101

Expert Comment

by:mlmcc
ID: 12013048
I don't think you can get at the text box values from Crystal.  

Instead of a text box create a formula

Name - MyTextBox
Formula
'My Name'

You should be able to use the formula in your other formula.

mlmcc
0
 
LVL 1

Author Comment

by:craduza
ID: 12013130
the problem is...the txtName value will always changed depending on user input
0
 
LVL 19

Expert Comment

by:GJParker
ID: 12014684
<< the problem is...the txtName value will always changed depending on user input >>

how does the value change ? text boxes can't be edited by users at run time.

Could you use a parameter field ? to hold the name and then use this in your formula.

Gary



0
Tech or Treat!

Submit an article about your scariest tech experience—and the solution—and you’ll be automatically entered to win one of 4 fantastic tech gadgets.

 
LVL 1

Author Comment

by:craduza
ID: 12014697
th value of the text box is changed within a VB Form. Just passing the value to the txtName on code
0
 
LVL 19

Expert Comment

by:GJParker
ID: 12014745
In that case you can use mlmcc idea nad instead of passing the value to a text box via code amend your code to pass the value to a formula.

create a formula with a single space inside double quotes.

then yuo can pass the value to this at runtime using the Text property of the formula object i.e.

Report.FormulaFields.Item(1).text = "My Name"

Gary


0
 
LVL 101

Accepted Solution

by:
mlmcc earned 150 total points
ID: 12023313
Actually you need to include the quotes in the text replacement

Use

Report.FormulaFields.Item(1).text = " 'My Name' "

or

Report.FormulaFields.Item(1).text = chr(34) & "My Name" & chr(34)

mlmcc



0
 
LVL 1

Author Comment

by:craduza
ID: 12042817
i've solved the problem. Just add the needed field in my query...:D thankz for ur help...:D
0
 
LVL 101

Expert Comment

by:mlmcc
ID: 12050409
Glad I could help

mlmcc
0

Featured Post

Tech or Treat!

Submit an article about your scariest tech experience—and the solution—and you’ll be automatically entered to win one of 4 fantastic tech gadgets.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Crystal Reports: 5 Tests for Top Performance It is complete, your masterpiece report.  Not only does it meet your customer’s expectations, it blows them out the water, all they want is beautifully summarised and displayed in a myriad of ways. …
I hate sub reports and always consider them the last resort in any reporting solution.  The negative effect on performance and maintainability is just not worth the easy ride they give the report writer.  Nine times out of ten reporting requirements…
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …

596 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