Setting <object><param> tag dynamically

I've got an ASP.NET application with an embedded Windows Forms control (similar to the old ActiveX controls).  Is there a way to set a <param> tag value  dynamically?  I tried a few things like...

<param name="DocID" value='<%=DocID() %>' />

and

<param name="DocID" value='<%# DocID() %>' />

and

<param name="DocID" value='<%# Request.QueryString("DocId") %>' />

without any luck.

Anyone have any  ideas?

Thanks, Alex

0
AlexB1318
2/13/2008 10:32:44 PM
asp.net.client-side 24353 articles. 2 followers. Follow

3 Replies
949 Views

Similar Articles

[PageSpeed] 43
Get it on Google Play
Get it on Apple App Store

 <param name="DocID" value='<%=Request.QueryString("DocId") %>' />

or you could perhaps take control of the entire element

<param name="DocID" id="DocIDParam" runat="server"/>

 

And in code-behind:

DocIDParam.Attributes["value"]="whatever";

 


-- "Mark As Answer" if my reply helped you --
0
gunteman
2/13/2008 10:49:02 PM

Hmmm...I think I read someone elses embedded client side object blew up when they tried running on the server, but I hadn't thought of just running the <param> tag server side.  I'll have to give it a try and see what happens.

0
AlexB1318
2/13/2008 11:36:48 PM

<param name="DocID" value='<%=Request.QueryString("DocId") %>' /> did the trick!  What a difference an equal sign makes.

Thanks for your help.

0
AlexB1318
2/13/2008 11:41:48 PM
Reply:

Similar Artilces:

How to strip a string of <html>, ,</html>, <body>, </body>, <form ... >, </form> tags?
I have stream which is the HTML input of a page. Now I want to use only that part of this page, that is within <form .....> and </form> tags, and excluding these tags.How would I go about stripping <html>, ,</html>, <body>, </body>, <form ... >, </form>, <head> and </head> tags? I have to make sure that <head ...javascript..> and its corresponding </head> tags are not stripped in this process.sun21170    Wait... you said you wanted to strip the head tags, and you're also saying you need to NOT strip the ...

>>>> Heads up <<<<
I just got a warning from Norton that "PamelaSetup-Basic.exe" has a virus in it. The name is "VirusBurst" Luckily, I did not install this software and Norton's quarantined it so I could delte it, which I have done. Symantec has not completed analysis of this particular piece of garbage but it did catch the sig. If you have installed Pamela, you may be in trouble. Duffy wrote: > I just got a warning from Norton that "PamelaSetup-Basic.exe" has a virus > in it. The name is "VirusBurst" > > Luckily, I did not install...

Programatically set an <object> <param> value
I am pluggin in a VRML viewer, but I must set the "SRC" param dynamically from the QueryString "?ID=1", perhaps in Page_Load(), perhaps some other way.  <object id="vrml" classid="CLSID:86A88967-7A20-11d2-8EDA-00600818EDB1" codebase=http://www.parallelgraphics.com/bin/cortvrml.cab#Version=5,1,0,167 width="300" height="300">     <param name="SRC" value="1.vrml" /> </object> How could I do this? I have figured it out.In the ASPX : <param name="SRC" valu...

>>>> ROOT Exploit in SAMBA <<<<<<
"A flaw has been detected in the Samba main smbd code which could allow an external attacker to remotely and anonymously gain Super User (root) privileges on a server running a Samba server. This flaw exists in previous versions of Samba from 2.0.x to 2.2.7a inclusive. This is a serious problem and all sites should either upgrade to Samba 2.2.8 immediately or prohibit access to TCP ports 139 and 445." http://us3.samba.org/samba/samba.html Binaries are available from Samba for RedHat, and some other distributions. So far as I can tell, the RedHat update mirrors I norm...

C<< >> vs C<< >> vs C<< x >>
Ugh. So we all know that there's this syntax for formatting codes (n=E9s "interio= r sequences") like C<< x >>. And that tokenizes as three tokens: "C<< ", open-C code "x", content " >>" close-code matching the C open-code And this is explicated by what I wrote in perlpodspec where I say that such a code... * starts with a capital letter (just US-ASCII [A-Z]) followed by two or more "<"'s, one or more whitespace characters, * any number of characters * one or more whit...

>>>> BUY RAM <<<<
.. ~~~*@@@*~~~ ================================================== ================================================== ENTER HERE: >>> http://web-for-you.cn/about/buy-ram <<< ================================================== ================================================== .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. ...

>>>> CAPITALS GAMES <<<<
.. ~~~!!!~~~ ================================================== ================================================== CLICK HERE TO ENTER: >>> http://web-paradise.cn/3/capitals-games <<< ================================================== ================================================== .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. ....

Inline tags...<%=%>, <%# %>, <%$ %> ....etc...
I come from a classic ASP background, so I know what <%= [string] %> means...but what about:  <%# expression %> and <%$ expression %>  --------------- I've seen <%# expression %> used mainly in databinding (<%# Bind("employeename") %>) for a TemplateField but am not sure exactly what it means (though I know what it does). I would think that <%= and <%# are synonymous but it seems they are not. <%$ expression %> I've only seen in an SqlDataSource when setting the ConnectionString attribute to: <%$ ConnectionStri...

Lists in .net
Like a good AKA accessible app building developer, my application's navbar is controlled with CSS and using <ul> and <li> I just have the code in the HTML display and it works fine when everything should be visible, however, I need to restrict some users from viewing certain navbar links based on their security levels.  How do I hide the list items that need to be hidden? TIA hello! give them ids and runat="server" attribute. then in code behind set the Visible property to false. orzeh code less, think more! Okay, I tried putting the link as a link bu...

Adding run-time created <li></li> tags inbetween <ul>/ul> tags
I want to create a custom control which will create a unordered list and fill it with list items of which will be created at run-time. Currently I am using the following logic: At my Default.aspx page:<ai:ul_adder ID="ul_adder1" ListItemString="Page1 1,sf1.aspx,image/edit.gif; Page 2,sf2.aspx,image/colaps.gif" runat="server"/>and at the ul_adder.ascx file 1 public string ListItemString 2 { 3 set 4 { 5 string[] itemlist = value.Split(';'); 6 7 for (int i = 0; i < itemlist.Length; i++) 8 ...

>>>> BLU-RAY MOVIES <<<<
.. ~~~!!!~~~ ================================================== ================================================== CLICK HERE TO ENTER: >>> http://web-paradise.cn/2/blu-ray-movies <<< ================================================== ================================================== .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. .. ....

Bug rendering <p> tags around <pre> or <code> tags
Name: Tim Robinson Email: tcr1272atgmaildotcom Product: Firefox Summary: Bug rendering <p> tags around <pre> or <code> tags Comments: Two Examples below, both render the <p> tags differently and incorrectly. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html> <body> <p> <pre> <div> my text </div> </pre> <p> <body> <html> <!DOCTYP...

How to remove <p> and <b> and <i> tags
Hi, I have some text in the database which has Html tags. I want that when I display the data the tags are removed.HighOnCodingWanna get high! You might consider called Server.HtmlEncode(data) on the rows to convert the html to characters that will be displayed in the browser.--Brian DesmondWindows Server MVP - Directory Serviceshttp://www.briandesmond.com Hi, Thanks for the Quick reply. Well now its displaying something like this: " &lt;P&gt;&lt;P&gt; &lt;i&gt;&lt;P&gt;if( dr.Read())&lt;P&gt;&lt;P&gt;{&lt;P&am...

[PATCH] correctly handle C<< >> and C<<< >>> in diagnostics
This is just a quick hack; ideally someone would make it use an actual pod parser. --- perl/lib/diagnostics.pm.orig 2003-12-30 15:48:47.000000000 -0800 +++ perl/lib/diagnostics.pm 2004-05-25 01:54:31.735904000 -0700 @@ -314,10 +314,10 @@ sub noop { return $_[0] } # spensive for a noop sub bold { my $str =$_[0]; $str =~ s/(.)/$1\b$1/g; return $str; } sub italic { my $str = $_[0]; $str =~ s/(.)/_\b$1/g; return $str; } - s/[BC]<(.*?)>/bold($1)/ges; + s/C<<< (.*?) >>>|C<< (.*?) >>|[BC]<(.*?)>/bold($+)/ges; ...

Web resources about - Setting <object><param> tag dynamically - asp.net.client-side

Resources last updated: 11/26/2015 10:39:26 PM