Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Setting properties of a page in the aspx file without using code blocks

Thread Tools

Setting properties of a page in the aspx file without using code blocks

Achim Domma
Posts: n/a

I have an aspx file which inherits from a class "MyPageClass" which
has a property "MyProperty". I want to set MyProperty in the aspx
file, but code blocks are not allowed in my environment (sharepoint).
I tried something like

<% @Page ... MyProperty="abc" %>

which does not work. If code blocks would be allowed the following
would work:

<% MyProperty = "abc"; %>

Is there an alternativ syntax to set the property? I don't see a
reason why this should not be possible, because it's quite normal to
set properties of controls in the aspx page. So why not for the page


Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Setting properties (not necessarily "Properties") in Java 5.0 Wardie Java 4 11-08-2006 09:46 AM
Syntax for call from aspx page to .cs file then to different aspx page MadHatter51 ASP .Net 1 05-17-2006 10:43 AM
procs/blocks - blocks with procs, blocks with blocks? matt Ruby 1 08-06-2004 01:33 AM
Cannot view any .aspx page without .aspx.cs present Jerry Tovar ASP .Net 1 10-23-2003 05:59 PM