Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » BIRT » Passing parameters via URL
Passing parameters via URL [message #1715751] Wed, 25 November 2015 16:16 Go to next message
Ingo Wolf is currently offline Ingo WolfFriend
Messages: 1
Registered: November 2015
Junior Member
Hello,

is it possible to pass parameters via url parameters (get/post) from a html form to a birt report for example:

MYDOMAIN/demoreport?myparameter=11111

demoreport = access birt report
myparameter = parameter passed to birt report

Thanks for any help,
Ingo
Re: Passing parameters via URL [message #1715946 is a reply to message #1715751] Sat, 28 November 2015 20:45 Go to previous message
Jerry Sheets is currently offline Jerry SheetsFriend
Messages: 76
Registered: July 2009
Location: Salt Lake City, UT
Member
Here is how I do it. I am using the Actuate/openText commercial version of BIRT.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>CP Contracts By Manager</title>
<link href="../css/dfcmstyle.css" rel="stylesheet" type="text/css" >

<script type="text/javascript" src="../inc/cal/calendar.js"></script>
<script language="JavaScript" type="text/javascript">
<!--
// Collect parameters and invoke ActivePortal to execeute report URL.
function doExecuteReport()
{
// serverURL, volume, userid, and authid are required parameters
targetURL = "http://birt.utah.gov/BIRTViewer/frameset?";

// *** Set Report Name
targetURL += "&__report=/Public/1347-ContractsByManager.rptdesign";
formObj = document.forms["BIRT1347"];
document.forms[0].action=targetURL;
document.forms[0].submit();
// window.alert(targetURL);

}
-->
</script>
</head>
<body>

<!-- Set Form Name -->
<form title="BIRT1347" method="POST" action="#">
<table width="90%" border="0" align="center" cellpadding="2" cellspacing="2" bgcolor="#9DBDDE"class="KT_tngtable">
<tr><td><strong><font size = 3><?php echo $_GET['ReportTitle']; ?></font></strong></td>
<td align="right">
<img src="SampleReports/1347-ContractsByManager.jpg" alt="Contracts By Manager" ></td></tr>

<!-- Parameters start -->

<!-- Project Manager -->

<tr>
<td colspan="2"><b>Project Manager:</b>
<select NAME="rprmAgency" Multiple size="5">
<option Value = "All" selected>All Project Managers</option>
<option VALUE = "125778">Doe, John</option>
<option VALUE = "118993">Garcia, Jerry</option>
</select></td>
</tr>

<!-- Project ID -->
<tr>
<td colspan="2" nowrap><b>Project:</b>
<input type="text" size="16" name="rprmProject" value="ALL"></td>
</tr>


</table>
<!--Advanced Actuate Parameters Section -->
<input type="hidden" name="__overwrite" value="old" />
<input type="hidden" name="__format" value="pdf" />
<input type="hidden" name="userid" value="" />
<input type="hidden" name="password" value="" />
<input type="hidden" name="__saveOutput" value="false" />
<input type="hidden" name="__requestType" value="immediate" />
<input type="hidden" name="invokeSubmit" value="true" />

<!-- Parameters end -->

<input type="submit" name="postback" value="Run Report" onClick="javascript:doExecuteReport();">
<input type="reset" name="Clear" value="Clear">
</form>
</body>
</html>
Previous Topic:MS SQL db only returning first 100 tables
Next Topic:Problem display component Line Chart
Goto Forum:
  


Current Time: Fri Mar 29 02:08:10 GMT 2024

Powered by FUDForum. Page generated in 0.07664 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top