another several questions

  • Thread starter Steve C. Orr [MVP, MCSD]
  • Start date
S

Steve C. Orr [MVP, MCSD]

I'll address your first question.

SmartNavigation is the simplest and most common solution for the postback
ugliness.
Here's more information:
http://msdn.microsoft.com/library/d...fSystemWebUIPageClassSmartNavigationTopic.asp

The alternatives to SmartNavigation get significantly more complicated.
You could use XMLHTTP to allow your controls to make their own calls back to
the server without have to refresh the whole page:
http://www.codeguru.com/Csharp/.NET/net_general/tipstricks/article.php/c9679/

This kind of thing gets easier in ASP.NET 2.0 if you can wait until then:
http://www.developer.com/net/asp/article.php/3506896
 
E

Eitan M

Hello,
2 questions about refresh.

1)
I want to do elegant refresh of the html page.

When refreshing a page,
the page is blink.
Is there anyway to refresh the page, without the blink
(something like in other languages :
1. freeze any changes
2. do the changes
3. unfreeze the changes
)

2)
How can I access the object of the client side of datagrid.
I mean : datagrid do some manipulations, add rows etc...
after that, the server send the results to the client side.
After I am in the client side, I want to access some of the elements on the
grid.
How can I do that ?

3)
Can dialog-box (called by window.showModalDialog) return result to the
calling form ?
If so, I need a sample please.

Thanks :)
 
E

Eliyahu Goldin

2)
How can I access the object of the client side of datagrid.
I mean : datagrid do some manipulations, add rows etc...
after that, the server send the results to the client side.
After I am in the client side, I want to access some of the elements on the
grid.
How can I do that ?
Your scenario is not clear.
3)
Can dialog-box (called by window.showModalDialog) return result to the
calling form ?
If so, I need a sample please.
In window.returnValue property. An example:
alert (showModalDialog("abc.aspx","","");
and somewhere in abc.aspx:
returnValue="Hello";
close();
 
K

Kevin Spencer

I'm afraid from the client side, YOU won't be able to change the text on the
"edit" button. Your HTML document could, though.

;-D

In fact, on the client side there IS no DataGrid. There is only HTML. It is
important to keep this in mind. The client-side HTML document has no
relationship to the server-side .Net entities that create it. It's just a
bit of .Net magick that makes it seem so. But if you want to be a true
magician, you will want to remain aware of these things. And you will not
want to refer to any of your tools as "I." I know this sounds picky, but if
you think I'M picky, you will find computers absolutely so.

YOU are the coder. The server-side processes you create, and the client-side
HTML documents and other client-side entitites are your creations. You only
control them at design time. At run-time, your code, the .Net platform and
the browser take over.

So, if you want your client-side HTML document to change dynamically, you're
going to want to use some Dynamic HTML. DHTML is an amalgam of HTML with
JavaScript and CSS.

Okay, so we're talking about a DataGrid here, so we're not necessarily
talking about ONE button. You're talking about AT LEAST one button. So, I
can't really be that specific, because you were not. I CAN tell you that you
would use JavaScript to get hold of the button and change its "value"
property. The "value" property of a button is the text on it. To get hold of
it, you can use document.forms[0].ElementName.value or
document.getElementById("ElementID").value. You could also use CSS, if you
are handling a client-side intrinsic event of the button.

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
Ambiguity has a certain quality to it.
 
E

Eitan M

Eliyahu Goldin said:
Your scenario is not clear.

Generaly , after I create the lines, on the aspx.
And now I am on the client side.
I have a grid, with some data.
When I am on the client side, I want to change, i.e, the text on the "edit"
button of the datagrid
(or whatever).

How can I do that ?

Thanks :)
 
E

Eitan M

Thanks.
You gave me an idea that works ...
(I have managed to change the contents of elements on the grid after I get
them to the client, by putting on the server side each of them an ID).

Thanks :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top