Solved

ActiveX and Passing Parameters

Posted on 2004-04-15
9
699 Views
Last Modified: 2007-12-19
I have an ASP application that uses CE9 to view reports on the web.

I would like to use the ActiveX viewer as my viewer.

The ASP page that the user's access allows users to select a myriad of parameter values (e.g. a bunch of drop down boxes).

I'm currently using the statement:

Response.Redirect("viewrpt.cwr?id="+id+"&apstoken.....)

to call the activex viewer. Using this method how do I pass parameters?

I can pass parameters using a vbscript that creates a viewer object and adding the parameter field to the collection.

Is there a similar method to create a viewer object for the ActiveX viewer???

HELP!!
0
Comment
Question by:jpmcclain
  • 4
  • 4
9 Comments
 
LVL 42

Accepted Solution

by:
frodoman earned 500 total points
ID: 10833620
You can use promptex to pass parameters in the url.  

I'm working from memory but I believe the syntax is:  &promptex-1=12&promptex-2=blue...
0
 

Author Comment

by:jpmcclain
ID: 10833634
I was hoping to avoid that method because users can select multiple values for each parameter. I thought that it might get messy if I put them in the url.

Thoughts?
0
 
LVL 42

Expert Comment

by:frodoman
ID: 10833706
I think they just go in the URL separated by commas:  promptex-2=blue,red,green&...

I haven't actually done this myself but from what I've read in the documentation it sounds like a straightforward process.  I don't have any other ideas w/in the CE framework.
0
 
LVL 100

Expert Comment

by:mlmcc
ID: 10835665
I believe that is correct.

mlmcc
0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 

Author Comment

by:jpmcclain
ID: 10836376
Is it worth trying something like this?

http://www.experts-exchange.com/Databases/Crystal_Reports/Q_20553244.html?query=activex+parameter&searchType=topic

Where I use a WebBroker??

Any good examples of this would be helpful.

0
 
LVL 42

Expert Comment

by:frodoman
ID: 10836462
I have not experience with this so I can't offer an opinion on it...
0
 

Author Comment

by:jpmcclain
ID: 10837587
I tried a simple promptex solution and I'm getting odd results.

Here's my code:

teststr = "&promptex-SelectionApplication='CARMS'";

Response.Redirect("viewrpt.cwr?id=" + id + "&apstoken=" + Server.UrlEncode(token) + teststr + "&init=actx:connect");

I'm still being prompted for the application value when the report runs? Its like viewrpt.cwr ignores the promptex command. Any ideas?

I also tried substituting promptex-1 inplace of the parameter name. No luck.

Any ideas?
0
 
LVL 42

Expert Comment

by:frodoman
ID: 10842079
Is the first parameter #1 or #0?  Should it be promptex-0 ?
0
 

Author Comment

by:jpmcclain
ID: 10845188
I got it to work.

I had to enclose the values in " instead of '

Thanks for all your help!

teststr = "&promptex-SelectionApplication=/"CARMS/"";

Response.Redirect("viewrpt.cwr?id=" + id + "&apstoken=" + Server.UrlEncode(token) + teststr + "&init=actx:connect");

0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Hot fix for .Net Crystal Reports 10.2.3600.0 to fix problems with sub reports running on 64 bit operating systems ISSUE: Reports which contain subreports fail with error "Missing Parameter Value" DEPLOYMENT SERVER OS: Windows 2008 with 64 bi…
Hello everyone, Hope you find this as helpful as we did. We have on the company I work for an application built in Delphi V with Crystal Reports 8. We all know that Crystal & Delphi can be temperamental sometimes and the worst thing is, nearly…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…
This tutorial demonstrates a quick way of adding group price to multiple Magento products.

747 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

11 Experts available now in Live!

Get 1:1 Help Now