|
-
Mar 26th, 2008, 03:33 AM
#1
Thread Starter
PowerPoster
[RESOLVED] Crystal XI Parameter default value question
Hi Guys,
I am adding a default value for a parameter like this in my vb code:
Code:
oReport.EnableParameterPrompting = True
oReport.ParameterFields.GetItemByName("Initials").SetNthDefaultValue 1, "nr"
This add nr to a combobox on the parameter prompt form that comes up in crystal. Proble is, that the first item in the combobox is ...
How can I make the first item the default value.
please help
-
Mar 26th, 2008, 05:33 AM
#2
Frenzied Member
Re: Crystal XI Parameter default value question
what is the default value?
-
Mar 26th, 2008, 07:49 AM
#3
Thread Starter
PowerPoster
Re: Crystal XI Parameter default value question
-
Mar 26th, 2008, 08:02 AM
#4
Frenzied Member
Re: Crystal XI Parameter default value question
I meant this
that the first item in the combobox is ...
-
Mar 26th, 2008, 08:04 AM
#5
Thread Starter
PowerPoster
Re: Crystal XI Parameter default value question
yeah it is those dots. I think Crystal adds it automatically.
-
Mar 26th, 2008, 08:11 AM
#6
Frenzied Member
Re: Crystal XI Parameter default value question
I've not seen it. Anyway while designing the parameter you have in the Options section Default Value why don't you use it?
-
Mar 26th, 2008, 08:36 AM
#7
Thread Starter
PowerPoster
Re: Crystal XI Parameter default value question
Because I want to retrieve a value from my database and then make it the default value. sorry, i know I mention I wanted the default to be "nr". my mistake.
-
Mar 26th, 2008, 07:40 PM
#8
Hyperactive Member
Re: Crystal XI Parameter default value question
I've noticed this also with XI and it is really annoying. Doesn't matter if you set defaults in the report as I am doing, it shows the same ellipses. If you do find an answer to this I'd like to know also. I never get any answers on the Business Objects website.
-
Mar 26th, 2008, 11:57 PM
#9
Frenzied Member
Re: Crystal XI Parameter default value question
Because I want to retrieve a value from my database and then make it the default value.
then have some control (textbox, DTP, Inputbox etc) from vb itself to receive the value from the user, if no value is given have your program to receive the value you had already retrieved from db. Remove that Enable prompt. I believe that is for asking info from CR itself, not for external program.
Code:
If len(trim(me.Text1.Text))< 0 then
'your default value
else
'value from you textbox
end If
-
Mar 27th, 2008, 01:24 AM
#10
Thread Starter
PowerPoster
Re: Crystal XI Parameter default value question
rasinc is right. It is extremely difficult to get a response on the Business objects website.
Let me explain in more detail.
The client wants to do the following:
I have a follow up date field and an initial field on my report. those are just 2 of the many I have. The user wants it so that when she clicks a print button then she must be prompted to clear the followupdate or add an initial. I have a parameter field inmy report with values of yes or no for clearing follow up date. that worked great.But now she wants to add an initial to the report. and these field must show on the report once printed. I had the followupdate working. Is they say yes when prompted the report suppresses the followupdate field.
Now with the initials I want the default value to be the last initial entered for that file. they can either choose that from a dropdown when prompted or type in another 1. The report will print with the initial selected and I will run an update query also to update that initial field in the table.
Now the problem with crystal is that those elipses are the 1st item in the combobox even if I add a default value for the parameter. and also if I type a value in the prompt textbox and then select the default value from the prompt combobox it doesn't change the value in the textbox.
I got so sick of it I just created a form with a combobox and a textbox and then I aassign those values to the parameters for the report.
Can anyone tell me how to do it in Crystal though. I'd love to know
-
Mar 27th, 2008, 01:55 AM
#11
Frenzied Member
Re: Crystal XI Parameter default value question
I got so sick of it I just created a form with a combobox and a textbox and then I aassign those values to the parameters for the report.
you did the right thing.
Since you are worknig from VB you could handle many elements of CR from vb itself, however if you pass the control to CR then CR takes over your program and you are servile to it. Set all the reqd parameters, SQLs, values from vb itself.
-
Mar 27th, 2008, 02:25 AM
#12
Thread Starter
PowerPoster
Re: Crystal XI Parameter default value question
Thanks for the advice VBFNewcomer.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|