|
You can't. Using timers on the server is useless in this context, as the server has no way of sending anything to the page after it has been created. Although the Page object may still remain in memory, it's response has already been sent to the browser, so doing anything to the Page object has no effect at all on the page displayed in the browser.
Anything that you want to do using time delay has to be initiated from the browser. AJAX is useful to do updates without having to reload the page, but still the request comes from the browser, the server can not send anything to the browser on it's own accord.
Use the window.setInterval method in Javascript to create a timer in the web page.
---
b { font-weight: normal; }
|
|
|
|
|
Is there any technique in .NET that I can use to push data to client's web browser? I have heard about COMET, but there is not any opensource. Any ideas?
|
|
|
|
|
mmiesi wrote: push data to client's
Push does not exist in reality. The client either polls or acts like a server that can be connected to for receiving notifications.
led mike
|
|
|
|
|
Yes, that's the kind of technology you'd have to use.
I'd suggest that you look a bit further, I bet there are some open source implementations. As COMET is a rather new name on technology that has been known for a while, there may be several implementations that does not (yet?) include COMET in their name.
---
b { font-weight: normal; }
|
|
|
|
|
or do you like just posting code.
modified 1-Aug-19 21:02pm.
|
|
|
|
|
Friggen annoying...WTF is he doing...
Now the forum is full of noise...useless...
CP should implement some lock on X number of concurrent posts without replies being posted by the same user...it would prevent goofballs like this from adding this much garbage to the forum...puching possibly important issues to the bottom of the stack - so to speak
It's frustrating being a genius and living the life of a moron!!!
|
|
|
|
|
Hi All,
I need to design architecture on a file handling application through web interface.
there will be limited no of users, and some DB logging will be there. so that database is not too complex.
Is it ok, if i have database server and IIS on the same machine, and having a file server separately ( i am talking of the physical machines).
Please provide your expert views on the same.
|
|
|
|
|
That should be fine, just be careful how you organize it and check that is it secure.
|
|
|
|
|
If u want to save/updates document file on the web server.
I think u should check Dotnetnuke or sharepoint service.
|
|
|
|
|
Is this doable?
We're looking to develop an application that allows you to enter a domain (www.thewebsitename.com) and have the application return a list of all pages associated with that domain. (www.thewebsitename.com/allthesepages).
Sanjeev
|
|
|
|
|
|
i have 3 projects in my .sln file.
1 - webproject (vb.net), 2 vb.net class library(Schemas) 3. c# class library (Managers).
i am passing Schemas object from code behind of web project to a method of Managers class.
it is giving an error as
"Reference required to assembly 'Schemas' containing the type 'Schemas.mySchemas'. Add one to your project."
All the references correct.
current references :
webproject having ref. to Schemas and Managers prjs
Managers having ref. to Schemas prj.
Please suggest me how to go about this issue.
Thank you inadvance.
-- modified at 1:24 Thursday 26th October, 2006
PradeepG
|
|
|
|
|
When you are passing an assembly's object to another assembly/Project. The receiver assembly/project should have the reference of sender's assembly.
In your case:
Webproject is having reference to both "Schemas" and "Managers"
but
"Managers" is not having reference to "Schemas", add the reference.
akhilesh
|
|
|
|
|
Hi Akhilesh Yadav,
Managers class also having a reference to 'Schemas'
This problem is giving when i am passing a vb.net class object to a c# class method.
It was working for vb.net class object to a vb.net class method.
Problem is peculiar
PradeepG
|
|
|
|
|
Correct me if I'm wrong
you are having three projects in sln.
1. Web Project -- VB.Net
2. Schemas (Class Library) -- VB.Net
3. Managers (Class Library) -- C#.Net
if all things are correct then check declaration of C# class method which will receive VB.Net class object. This error is in relation to referecne only.
Regards,
Akhilesh Yadav
|
|
|
|
|
code behind of web app.
Imports Schemas
Imports Managers
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim objSch As New mySchemas
Dim objMan As New myManager
objSch.FirstName = "Scott"
objSch.LastName = "Perk"
objMan.AccessSchema(objSch) 'Error in this line :objSch
'Error during compliation
End Sub
-------myManager.cs----------------
using System;
using Schemas;
namespace Managers
{
///
/// Summary description for Class1.
///
public class myManager
{
public void AccessSchema(mySchemas objReg)
{string FN,LN;
FN = objReg.FirstName;
LN = objReg.LastName;
}
}
}
--- MySchemas-----
Public Class mySchemas
Private strFirstName As String
Private strLastName As String
Sub mySchemas()
strFirstName = ""
strLastName = ""
End Sub
Public Property FirstName() As String
Get
Return strFirstName
End Get
Set(ByVal Value As String)
strFirstName = Value
End Set
End Property
Public Property LastName() As String
Get
Return strLastName
End Get
Set(ByVal Value As String)
strLastName = Value
End Set
End Property
End Class
PradeepG
|
|
|
|
|
Sorry for late reply.
I checked your code. It's absolutely fine.
I tried giving the project references.... got the problem.
Then I tried giving reference from DLL i.e copy paste the dll in web project's bin folder and then give reference from bin.
Solution was sucessfully built.
Regards,
Akhilesh Yadav
|
|
|
|
|
Thanks Akhilesh. I also did the same thing.
PradeepG
|
|
|
|
|
Recently I'm working on a network application which is implemented with WinInet and provides HTTP access to internet.
And it works well for direct connect and HTTP proxy situation, except the case where customer's environment needs the information of domain name during proxy authentication, which means there's a domain-controller server in customer's office.
Since the WinInet API like InternetSetOption supports only the "Username" and "Password",how and where to specify the "domain" name?
I've referred to MSDN, but could NOT find information about that.
Thanks for any comments.
Chairman
|
|
|
|
|
Hi Friends,
I have developed a file uploading utility which uploads file.
my problem is.
When i get the conents of the folder and list my files on the page.
I want to give the option of downloading that file.
When there is no space in the name of file it works, it allows to download but
when there are spaces between the file name it just shows the first word of file name
for example
file name is
my resume.doc
my utility will only allow to fownload file when i change its name to
myresume.doc
otherwise it will show under link only
my
can any one help me how to reslove this problem.
i am using classical asp.
Naveed Kamboh
|
|
|
|
|
Normally I would ask you to show some code, but I am pretty sure about the two bugs that you have in your code that causes this.
Bug #1:
You have forgotten to put quotes around the href attribute.
Bug #2:
You have forgotten to url-encode the file name.
Your code, that probably looks something like this:
<a href=<%=objFile.Name%>>Download</a>
should be looking like this:
<a href="<%=Server.UrlEncode(objFile.Name)%>">Download</a>
---
b { font-weight: normal; }
|
|
|
|
|
Thanks dear,
there were no bugs which you mentioned.
That routine to fill the table was in a seprate page,
I was including that page into that page where I wanted to show that table.
When put that code directly to the page every thing was working.
Problem is solved but I dont know why it was not working while i was includeing file and calling that function.
Naveed Kamboh
|
|
|
|
|
Sorting is indeed simple but i am not getting how we can make
use of sorting in paging environment so that all pages should
get sorted when we click on the column heading.
|
|
|
|
|
You have to do the sorting before the paging. You have to know the order of all the items, before you can get the items that should be shown on a specific page.
---
b { font-weight: normal; }
|
|
|
|
|
If you're binding a dataview, you can sort the entire dataview.
|
|
|
|