Showing posts with label time. Show all posts
Showing posts with label time. Show all posts

Wednesday, March 28, 2012

Atlas works on Dev. Machine - not on IIS

hi,

I have installed Atlas - and just tried the simple example with the Labels and Time refreshing.

Works perfectly on the development machine, although it doesnt work once i publish it to the IIS server.

any ideas as to how to get it to work?

thank you.Depends on what the error is...

ATLAS WITH EXPLORER

I want to use atlas in my project, but someone tell me that atlas work very good with firefox but no work with explorer and many time faild the explorer.

is atlas and explorer work together also in big projects?

thanks!

Hi,

you can surely use Atlas with Internet Explorer.

Monday, March 26, 2012

Atlas update progress

I have page with large execution time, so I use updateProgress to show the user, taht the page is still calculating:

<atlas:UpdateProgress ID="up" runat="server">
<ProgressTemplate>
<div class="progress">
<img src="http://pics.10026.com/?src=../images/indicator.gif" />
Calculating...
</div>
</ProgressTemplate>
</atlas:UpdateProgress
I would like that user see the indicator as long as the server is calculating results .
But when 90 seconds is passed, my indicator is gone and user thinks that
calculation is done.
If I remove atlas, than page is generating 3 minutes(server.scriptTimeout is setted to 1000 seconds).
Any idea how to enlarge execution time of atlas update progress?

Regards,S

Hi there,

The timeout period for async postbacks with UpdatePanels is currently hard-coded to be 90 seconds. I don't know of any workaround in the CTPs, though this issue will be addressed in Atlas 1.0.

Thanks,

Eilon

Atlas update panel request timeout

I have annoying problem. Page has EnablePartialRendering="true" and several Update panels. Page works fine if Request is short, bit some time it can take up to 5 minutes to finish respond, and in this case, page does not return anything. I guess it has to be some TimeOut async request reaches. I tried to set <pages asyncTimeout="600"> - it does not help. Would appreciate any advise.

hello.

use the scriptmanager's AsyncPostBackTimeOut property to define the timeout associated with a partial request.


You may also consider manually calling the update panel .Update() - if its a long request and on the browser side its taking awhile - you could do this:

<Update Panel>

<Panel id="pnlForm" >

insert control here or whatever

<Panel if="pnlStatus">

Display message will take a while - do not navigate from page...

write a short javscript method that when you know it will be a long request... will toggle on the postback the second panel...I suggest using the style='display:none' instead of the .net visible = true or false...

Then in code behind do your work and at the end reissue the css style select to trigger them back to original status...and then call the updatepanel.Update()...

That may work as a solution for something of that time period...Since we are talking asynch - and you have other update panels - this should theoretically allow other stuff to happen - and still handle your first request.. I don't know for sure if that will work

I have noted that even setting the asynch timeout - with IE in particular it will not process a direct postback after x period of time...

But - I do think a better solution - is to figure out why it takes 5 minutes to perform something for a web client. If its a report generation - then the best thing to do is write kinda a job queue that stores the results - and has a status flag it updates... then on the web client poll the job status and when available trigger the update for the update panel...


Hello

I don't see AsyncPostBackTimeOut among ScriptManager properties.

Thanks


If you are using Atlas - I don't think that property existed - its a property of the new Beta however...

Saturday, March 24, 2012

Atlas Triggers not quite woring

Hi,

I have got a serious problem with triggers not updating the content of UpdatePanel at appropriate time. Here's the situation:

The master page holds three fieldset elements - each of those is dragable and resizable (YUI library). Inside each of those is an UpdatePanel. Each UpdatePanel holds part of the left side menu, so parts are separately draggable around the UI.
Next, the page that uses this master page further has four (4) more draggable fieldsets with UpdatePanel's inside. Each of these panels holds a part of the final content - drill down. So I need to update each lower UpdatePanel when the upper one changes. Each of the content panels actualy holds a WebUserControl (.ascx) and those all inherit from a base control that defines and fires a common event when something changes. This works. I debugged the event firing and it works just fine. The problem is that when i created Triggers and defined the controls that fire them and the common event nothing really happens. All those UpdatePanel's have their Mode set to Always so they did get updated even before i added triggers with a small problem that they got update after two clicks, thous showing what should have been shown one click back. Triggers actualy made no diference even dough I thought they would.

If anybody has had the same problem and have sessed it please post your solutions. Should the UpdatePanles have their Mode set to Partial in order for triggers to work?Hi LoneTiger,

This forum is specifically devoted to the"Atlas" Control Toolkit. You'll probably get a much better response if you post this question in either the"Atlas" Discussion and Suggestions or the"Atlas" UI forums where theUpdatePanel experts are.

Thanks,
Ted
Thanks Ted. I reposted the question at suggested forum. Is it possible to delete this one?

Atlas trigger not quite working

Hi,

I have got a serious problem with triggersnot updating the content of UpdatePanel at appropriate time. Here's thesituation:

The master page holds three fieldset elements -each of those is dragable and resizable (YUI library). Inside each ofthose is an UpdatePanel. Each UpdatePanel holds part of the left sidemenu, so parts are separately draggable around the UI.
Next, thepage that uses this master page further has four (4) more draggablefieldsets with UpdatePanel's inside. Each of these panels holds a partof the final content - drill down. So I need to update each lowerUpdatePanel when the upper one changes. Each of the content panelsactualy holds a WebUserControl (.ascx) and those all inherit from abase control that defines and fires a common event when somethingchanges. This works. I debugged the event firing and it works justfine. The problem is that when i created Triggers and defined thecontrols that fire them and the common event nothing really happens.All those UpdatePanel's have their Mode set to Always so they did getupdated even before i added triggers with a small problem that they gotupdate after two clicks, thous showing what should have been shown oneclick back. Triggers actualy made no diference even dough I thoughtthey would.

If anybody has had the same problem and havesessed it please post your solutions. Should the UpdatePanles havetheir Mode set to Partial in order for triggers to work?

Last time I saw this "one-update-behind rendering" problem (for lack of a better term), it was a bug on my side; I was updating the data too late in the page lifecycle (so the UI had already been rendered).

A simple test to see if you have the same bug would be to take Atlas out of the equation. (Probably setting EnablePartialRendering="false" on your atlas:ScriptManager should be enough.) If the problem is still there when using normal postbacks, then you know that Atlas isn't the problem. On the other hand, if it starts working just like you'd expect (but full page refreshes, of course), then you know it's somehow related to Atlas.

As always, the best way to get help would be to create a really minimal Atlas app that demonstrates the problem and post the full code. That way other people can read through it and even try it on their own.


Hi Steve,

I tested Atlas behavior with creating a test project with one page (no master page). Then i created 2 web user controls (.ascx), added 2 UpdatePanels to the page and within each one I placed one of those user controls. Each user control contains a button which increments its number of clicks and the oposite control displays that number.

This composition works well if i set the UpdatePanels mode to Always - the user controls displays the correct number. If I set the mode to Conditional, the control - as expected - gets updated only when one of its contained controls has coused postback.

Next i tested adding Triggers to each of the UpdatePanels and link the controlId to oposite user control button and event name to click event. And afcourse setting the mode to Conditional. This also works very well.

Then I added events to controls themselfs. When the button within the control is clicked that event gets fired from the button click handler. And the user control event is then used as the target event in the UpdatePanel Trigger. Here is the problem. I am probably doing something wrong with page / user control as you suggested. Funny thing is this is a very simple page (no added code behind) and two very simple user controls. Each of user controls contains a method InnitializeControls() which sets the .Text property of the label. This method is called from Page_Load.

Is there some special way controls have to be written in order for Triggers and the Conditional Mode to work correctly? I would expect that trigger would update the panel after its target has finished initialization or after all other event handlers have finished. At what point are the triggers called? Should this involve any event bubbling?

Anyways, I need UpdatePanels to update based on user control event - the control is contained in another UpdatePanel. The problem can be fixed by explicitly setting the event handler to the publicly defined method in the control that needs to get updated when the event emiter changes. and setting the Mode to Always.

I hope there is a better way because this approach has a lot of overhead. I just don't get it why it works with buttons but not with user control events. Has this anything to do with client side clicks?

Thanks for any suggestions.

Atlas toolkit Rating Demonstration

What a great extention for the toolkit. I am going to use it in my logs and polls. I took some time and created several other graphics for the rating and with a few modification of the css file was able to get them to look farely nice. I made three new ones for now: Baskeball, baseball, and hearts. Go to my blog at

http://fitness1st.net/blog to download the files.

The sample fit into the toolkit sample web. Replace the image folder, Ratings folder, and the StyleSheet.css and it should work fine. I did not re-implement the hotness rating however.

Thanks for such a fun tool.

T

Thanks !

Can I add you 3 nice samples in Toolkit Sample ?


Yes you may use them.


I am having difficulting with changing the CurrentRating above 5, when I also change the MaxRating to above 5. Is this a bug?

I have created a Physical Activity Calculator which I am going to turn into a physical activity log/journal when I am done. The ap is just a shell at the moment, but you will get the idea of how I am using the rating scale as a slider. I wish we had a slider in the toolkit. Well anyway...

http://fitness1st.net/fitlog/log/default.aspx

Enjoy!

Please let me know about the error

Atlas Slow first time load

Hey guys,

I hope this is the right forum for posting this. I'm using Ajax 1.0 and the ASP.NET AJAX Control Toolkit.

The problem that I'm having is that the very first time I visit the page, or when the page has been sitting idle for 20 minutes, it takes about 25 seconds before it comes up. After it loads up once, I can refresh and it loads up within less then a second. I have enabled Trace output, and it tells me that the page is loading up in .5xxxx seconds, but from a users perspective when they hit the page, it takes 25 seconds. This happens with the ASP.NET AJAX Control Toolkit sample website as well.

I have set<compilationdebug="false">and it's had no effect. The server that it's on is a new Intel Woodcrest on a RAID 5, so it should be plenty fast enough. Compiling it in Visual Studio takes 1-2 seconds.

I'm not sure what's going on, but for about 23 of the 25 seconds there is no CPU utilization going on. Here is a picture of Task Manager to show what's going on. The stuff in the red box shows when I refreshed the page after I restarted IIS.

Free Image Hosting at www.ImageShack.us

Anyone have any ideas on what's going on during the 20 seconds of the CPU not doing anything?

Thanks,

-Will

Hmmm, that's a new one. Some questions. Do you see this behavior with a standard ASP.NET application? Are you sure the pause is on the server side and not the client side (e.g. is your browser proxy configured right, etc.)? Is the server busy doing something else? Maybe check disk activity during that 20s.

Thanks for the response.

I do not see it with a standard ASP.NET application, but I've only tried out a very basic application. I have tested this on 2 different web servers that we have. I get the same pause when I view it on a browser on the server, or on another computer targeting an Ajax Control Tooklit page. I have also looked at disk I/O as well during the pause. There is some but it's very minimal. I've disabled the Virus scanner to see if it's causing anything. The only things really installed on them, because I just built it, are Windows 2003 Enterprise Edition, Mcafee Virus Scan, IIS 6.0, Visual Studio 2005, Ajax v1.0, and the Ajax Control Toolkit.

I'm suprised, that other people aren't experiencing this. I've experienced it on 2 computers now. I thought it had something to do with having .NET 3.0 RC1 and the orcas stuff, but I just did a brand new clean install on another machine and I'm getting the exact same pause.

Any other advice or suggestions would be appreciated.

Thanks


Hi, i am having the same problem. It seems that the page is trying to download the whole toolkit dll every time the page loads. I am on a 56k connection and the page takes about 2 mins to open. The same happens when i try to open this site (asp.net site). Has any solution been found for this?? Thanks.


Could you maybe get a complete trace with Fiddler so we can get an idea what's going on?


I'm currently working on a client issue involving a ASP.NET Website. This site initially takes 25 seconds to load on a Windows Server 2003 OS.

The same ASP.NET Website loads 2 seconds initially on a Windows Server 2000 OS. The website uses the Reports Server control for report viewing.

Perhaps a previous post gives a hint in the direction I might take to figure this out! (i.e., DLL Load Time)!

Stay posted!


After my ASP.NET website sits idle for more than 20 mins the next request is very slow. The reason is that the application domain is flushed from IIS and the application needs to be recompiled. I found this utility to be handy.http://www.spikesolutions.net/ViewSolution.aspx?ID=c2b7edc0-5de1-4064-a432-05f6eded3b82

Wednesday, March 21, 2012

Atlas Re-Orde List - DataBinding from SQL 2005

I've had no problems working with this control using DataSources declared in the .ASPX page. However, I am having a fun time trying to get this working with DataBinding from our DataBase.

Where I have gotten so far:

List Renders

List Will Re-Order perfectly

List Will Post Back only to the Page_Load event... no other event

I have the event: rlValues_ItemReorder declared and it should be going to that event, but it doesn't.

During postbacks to the server, I check to see how many items the Re-Order list has in it, and it tells me 0. I had the original DataBinding in an if(!IsPostBack) on the page load, and I've changed it so it binds on each page load. I'm not sure which one I need.

Here is the code I am working with:

Item.Fields.FieldList objFieldList;

int intFieldID = 1;

protectedvoid Page_Load(object sender,EventArgs e)

{

objFieldList =newItemManagement.Item.Fields.FieldList(base.GeneralSettings.ConnectionString, intFieldID);

BindData();

}

privatevoid BindData()

{

rlValues.DataSource = objFieldList.ListValues();

rlValues.DataBind();

}

protectedvoid rlValues_ItemReorder(object sender, AtlasControlToolkit.ReorderListItemReorderEventArgs e)

{

thrownewException("The method or operation is not implemented.");

}

protectedvoid btnInsert_Click(object sender,EventArgs e)

{

if (txtValue.Text !="" && txtText.Text !="")

{

objFieldList =new ItemManagement.Item.Fields.FieldList(base.GeneralSettings.ConnectionString, intFieldID);

objFieldList.InsertValue(txtText.Text,Int32.Parse(txtValue.Text));

BindData();

}

}


Here is the .aspx side I'm working with:

<atlas:scriptmanagerid="ScriptManager1"EnablePartialRendering="true"runat="server">

<ErrorTemplate>

<divstyle="padding: 12px; width: 400px; height: 140px; border: #000000 1px solid;

background-color: white; text-align: left">

An error has occurred:<br/>

<spanid="errorMessageLabel"runat="server"></span>

<br/>

<br/>

<inputid="okButton"runat="server"type="button"value="OK"/>

</div>

</ErrorTemplate>

</atlas:scriptmanager>

<divclass="reorderListDemo">

<atlastoolkit:reorderlistid="rlValues"runat="server"

allowreorder="true"draghandlealignment="Left"iteminsertlocation="Beginning"

datakeyfield="FieldListValueID"sortorderfield="Order"Width="90%"OnItemReorder="rlValues_ItemReorder">

<ItemTemplate>

<divclass="itemArea">

<asp:LabelID="lblText"runat="server"Text='<%# Eval("Text")%>'/> |

<asp:LabelID="lblValue"runat="server"Text='<%# Eval("Value")%>'/>

</div>

</ItemTemplate>

<ReorderTemplate>

<asp:PanelID="Panel2"runat="server"CssClass="reorderCue"> </asp:Panel>

</ReorderTemplate>

<DragHandleTemplate>

<divclass="dragHandle"> </div>

</DragHandleTemplate>

</atlastoolkit:reorderlist>

<hr/>

<asp:LabelID="lblOutput"runat="server"/>

<hr/>

Value:<asp:TextBoxID="txtValue"runat="server"/>

<br/>

Text:<asp:TextBoxID="txtText"runat="server"/>

<br/>

<asp:ButtonID="btnInsert"runat="server"Text="Insert"OnClick="btnInsert_Click"/>

</div>

Any help would be awesome.

Thanks.

I believe you need to rebind each time. Without rebinding the list thinks it has zero members, and (using the latest drop from CodePlex) throws exceptions in (as I recall) reorderList.cs ('Item index > count' or something like that). Further code there invokes the Reorder function, so if it bombs out your reorder function never gets called.

The main issue I see with my example is that It never hits the re-order event (if that is what you mean).

The Version I'm using is the newest one from CodePlex... but I have yet to see any errors from the control.


Shawn helped me with this. If I take the Order field out (seeing i'm binding with an IList) it works perect.

Atlas quirk in IE 6

Hello all,
First time Atlas user over here, and I just wanted to say that I'm damn impressed with the toolkit.. that and I've noticed a graphical quirk in IE when using Atlas.

I currently have a master page with everything positioned in CSS (menus, background, content etc). I have a small section of my default webpage use atlas to update a a label from a textbox after I click a submit button (basically: lblChat.text=TextBox1.text;). The thing works fine in firefox, however, in IE 6 when I click on the submit button the background of the webpage flashes to grey for a second (the page doesn't refresh though, just the background disappears for a second).

I have set the background of the webpage in a CSS file as follows:
body
{
background-image: url(Images/background.jpg);
background-attachment: fixed;
}

Any idea why this is happening?

Thanks.

Styles are re-sent to the page on any callback, to enable the serv-erside processing to change the stylesheet as well as the data. So if the background is set via CSS, this will refresh, and may cause a flicker as the browser re-paints.

It does seem like a pain in situations like yours, but it is really handy being able to change the styles for the whole page without having to re-query the data for the whole thing (when you want that behaviour).

Richard.

ATLAS Prototyping Gone Awry?

Hello,

The company I work for has spent some considerable time developing a WYSIWYG/TextArea custom hybrid editor for our forums and websites. Within the javascript file for this editor we have the following line...

var btn = toolbarArray[btnGroup][btnItem].toLowerCase();

This works all well and good, that is, until I include the ATLAS xml block on the control...

 <atlas:ScriptManager runat="server" id="scriptManager"> <services> <atlas:servicereference path="~/Services/EmailService.asmx" /> </services> </atlas:ScriptManager>
Now, the once simple var[array][array] is tranformed into something compeltely different.
It now becomes var[array](function). The following is a copy/paste from an alert window displaying the function contents...
--------
Microsoft Internet Explorer
--------
function(index) {
    return this[index];
}
--------
OK
--------
Now why on earth is ATLAS going around prototyping stuff it has no business messing with? This is basically killing our ability to use our editor on any ATLAS enabled page.
 

hello.

hum...not sure if i follow you...are you saying that atlas changes the meaning of predefined methods? could you give more info on that problem?


There's not much more info to give. If you have an understanding of javascript's syntax the issue is pretty easy to follow.

Before the ATLAS xml block is used this is valid...

var btn = toolbarArray[btnGroup][btnItem].toLowerCase();

After the ATLAS xml block is used the above becomes invalid and the following becomes valid...

var btn = toolbarArray[btnGroup](btnItem).toLowerCase();

The difference is pretty significant, and we've spent a large amount of time narrowing the issue down to the fact that in the normal case, ATLAS is not used. Once ATLAS has been added to a page, it appears to prototype our standard var[array][arrayindex] to var[array](arrayindex). It basically changes a standard getItem on an array object to a function (which I pasted in my first post).

This is hugely irresponsible and is breaking a large amount of our code.


hello again.

well, i have basic javascript knowledge, but i think i will be able to follow if you're able to give a concrete example of this problem (ie, can you build some sort of sample and past it here so that i can understand what's going on?). to my knowledge, the array object has been augmented with new methods and none of the previous ones has been changed. the team has also extended the function object extensivelly to improve oo programming in javascript.


var toolbar = [['1'], ['2'], ['3', '4']];

for(var item in toolbar)
{
var thing = toolbar[item][0];
}

Run it without ATLAS and thing will return '1'

Run it with ATLAS and thing will return that function definition I pasted in the first post.

This has been confirmed for Opera 9, Firefox 1.5.0.4 and IE 6 XPSP2


hello again.

ah, oki...you've got a point. Expanding the array object introduces several metods to its prototype property (which i think is empty by default). that's why you'd get the expected results when you used that syntax when you didn't add atlas to your app. btw, there's a quick fix for this: use the traditional for approach or use the new forEach method that's appended to the array class.


Great, I'm glad I'm not the only one seeing this. Was thinking that my mind took a vacation.

You are correct, you can fix this by taking the traditional for(var i = 0; i < x; i++){} route. However, the ATLAS team is breakingEXPECTED functionality. That's where the problem lies. I've searched the documentation and can find no mention of this. It should definately be rectified, and at the very least, well documented.

I'm hoping that this post helps out some other developers in the future, and that the team takes a look at this post and makes a note of it. Thanks for your participation.


hello.

well, in my opinion, the documentation on msdn (jscript center) is wrong because i think it shoud only say that it returns each property of an object instead of giving the impression that this is different with arrays (which, in my opinion, is not correct)...


I would agree with you if not for the fact that this is standard behavior in every js engine/implementation I have been able to find.

hello again.

well, yes, i understand what you mean...what i'm trying to say is that the way the arry behavior is a side effect of the way it's defined...for instance, if i'm not mistaked, the javascript says something like this about the for...in statement:

The

for...instatement iterates a specified variable over all the properties of

an object. For each distinct property, JavaScript executes the specified statements

in the

block.

ForInStatement:

for (Identifier in ObjectReference) Block

ObjectReference

is an identifier that is the object for which the properties are

iterated.

though i might be wrong, to me it looks like this syntax should only be used to iterate over all the properties of an object (that's why i say that the array default behavior can be seen as a side effect of the way it's used).