473,770 Members | 1,996 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

changing textboxes in a report at run time

Hello all,

I have a report that displays four pieces of data by default, but two
of these fields are not neccessary for all people to see.

I have made a form that gives the user the choice to select what data
to display when the report is being run. After the selection has been
made on the form, the report is opened in design mode, saved, closed
and reopened it in preview mode. I was wondering if there is a cleaner
way to modify the report than opening it in deisgn, and then reopening
it in preview mode?

Tim

Aug 16 '06 #1
2 1326

<tr*****@gmail. comschreef in bericht news:11******** **************@ m79g2000cwm.goo glegroups.com.. .
Hello all,

I have a report that displays four pieces of data by default, but two
of these fields are not neccessary for all people to see.

I have made a form that gives the user the choice to select what data
to display when the report is being run. After the selection has been
made on the form, the report is opened in design mode, saved, closed
and reopened it in preview mode. I was wondering if there is a cleaner
way to modify the report than opening it in deisgn, and then reopening
it in preview mode?

Tim
You could do this in runtime, while the report opens

On your report I would make the choice-controls invisible.
On your form e.g. called FrmDisplayChoic e you need two controls like
ShowControl1 and ShowControl2 (yes/no values here)
Then you need some code in the report's open-event like
Me!Control1.vis ible = Forms!FrmDispla yChoice!ShowCon trol1
Me!Control2.vis ible = Forms!FrmDispla yChoice!ShowCon trol2

Arno R
Aug 16 '06 #2
Thank you for the help. That is much easier to deal with.

Tim
Arno R wrote:
<tr*****@gmail. comschreef in bericht news:11******** **************@ m79g2000cwm.goo glegroups.com.. .
Hello all,

I have a report that displays four pieces of data by default, but two
of these fields are not neccessary for all people to see.

I have made a form that gives the user the choice to select what data
to display when the report is being run. After the selection has been
made on the form, the report is opened in design mode, saved, closed
and reopened it in preview mode. I was wondering if there is a cleaner
way to modify the report than opening it in deisgn, and then reopening
it in preview mode?

Tim

You could do this in runtime, while the report opens

On your report I would make the choice-controls invisible.
On your form e.g. called FrmDisplayChoic e you need two controls like
ShowControl1 and ShowControl2 (yes/no values here)
Then you need some code in the report's open-event like
Me!Control1.vis ible = Forms!FrmDispla yChoice!ShowCon trol1
Me!Control2.vis ible = Forms!FrmDispla yChoice!ShowCon trol2

Arno R
Aug 16 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
4031
by: Phin | last post by:
I need your HELP! I've seen all the posts on using Crystal Reports within vs.net (vb.net) and changing a SQL query at runtime. When I tried to pass in a dataset into the crystal report at runtime, the report still showed the results from the default query (from within the Crystal Report). Then I tried the XSD solution where you define a dataset (that mataches the database and the Crystal Report) and have the Crystal Report use this....
0
1180
by: Ahmed Hashish | last post by:
If I have a report connects to access database how could I change it to connect to sql server database at runtime from my asp.net application. Ahmed
2
5301
by: bill | last post by:
I understand how to change the URL of a web service at run-time. But, if I am using a web service in a windows application, what is a good way to inform the application of the current location of the web service, without recompiling and redistributing the application?
2
1502
by: bh | last post by:
Changing a Date Time Value I have a form with a date time picker or it and a button. When the button is pressed it passes the date/time into a stored procedure that queries an SQL database. Because the date time format is different I am receiving an error. I want the date format to be “dd-MMM-YYYY HH:MM:SS” e.g. “31-Dec-2006 23:59:59”
2
1733
vdraceil
by: vdraceil | last post by:
Is it possible to find whether the current system date is changed or not with VB6.0 code?All i want to do is to prohibit the user from changing the system time.How can i do that?
1
1418
by: Mehrdad | last post by:
Hi all, How can I find that the size of my userControl is changed (at design time)? when a user changes the size of the user control at design time, I do need to make some correction on the changed size when the AutoSize property is true. Any help would be appreciated. Thanks,
0
1271
by: r | last post by:
Hi all I have a microsoft report in my program that has a Textfbox field and Image field.(I have an external image ) How can I change value of these controls at runtime?? (without using datafield ) thanks in advance
0
9454
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10259
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10038
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
7456
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupr who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6710
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5482
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4007
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3609
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2849
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.