|
please can you help me in getting this.
|
|
|
|
|
You can't do it in ASP.NET. You CAN do it in an activex control or java applet.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
ok.is it possible when it is a server side ?
|
|
|
|
|
Again - you cannot use ASP.NET code to read the file system on the client. You can host an ActiveX control or Java control ( making this not an ASP.NET question ) which will do what you want. Yes, by definition, these are hosted on the server and work on the client.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
|
Well I guess if you have not yet completed that brick wall for slamming your head into, this is fair substitute.
led mike
|
|
|
|
|
So I guess you thought my decision to abstain was premature? Now what do you think?
led mike
|
|
|
|
|
*grin* I could hear your cries of frustration, as I read the thread.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
What you want is physically not possible. Imagine if you could write code that accessed a clients file system, deleting and looking at files ? No-one would use the web if this were possible.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
hai this is anitha
am developing an asp.net project on road maps . road maps are inserted in to a imagemap at runtime.i want to create a code for changing the color of the the entire road in which mouse is clicked . (imagine there is no junctions)the code should able to move through the road from starting pixel to the ending pixel of the line on both direction.
thanks in advance
modified on Thursday, December 4, 2008 1:12 PM
|
|
|
|
|
1 - don't ask twice
2 - there is no flood fill in GDI+, don't ask me why. You can interop to use the C++ flood fill method.
3 - of course, you realise that doing it this way means you need to use javascript to detect a mouse click, then send the point to the server, then the user has to wait while the new bitmap is created and then loaded on the client again ?
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
Just to be more clear, there is no way you can do what you're asking in ASP.NET. If you want it to happen on the client end, it will have to be in an activex control or applet.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
hai this is anitha
am developing an asp.net project on road maps . road maps are inserted in to a imagemap at runtime.i want to create a code for changing the color of the the entire road in which mouse is clicked .
thanks in advance
|
|
|
|
|
Hi All,
We have a problem..We have developed asp.net web project and ready to deploy. Now we have 2 servers.We are thinking to upload database to another server and website to other server. Is it giving us best performance rather than uploading database and site to the same server?
please send your ideas about that.
thanks in advance.
|
|
|
|
|
It depends on a whole lot of things.
1 - how many users do you have ( is there a need at all ) ?
2 - how well written is the database code ?
3 - how well connected are the two servers ( are they in the same room, or is one in Paris and one in Delhi ) ?
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
|
I've created a few web services that have a ServiceStatus WebMethod that will eventually return the status of the web service. Right now I just get them to return a string just to make sure they work, eventually they'll return either "Good", "Critical", "Moderate".
When I access the services and invoke the ServiceStatus method it works fine, if I try it a second time I get the following error:
System.ArgumentException: An item with the same key has already been added.
I think it may be because of the way my web services are architected. I have a base webservice that implements the ServiceStatus method and this web service class is declared as abstract, the ServiceStatus in the abstract class calls an abstract method, ServiceHealth which is implemented by the inheriting web services to respond with their health.
So basically the base class has this:
///
/// Returns the current state of the service
///
/// <returns>
[WebMethod]
public string ServiceStatus()
{
return this.ServiceHealth();
}
public abstract string ServiceHealth();
and then the inherited class simply implement ServiceHealth as:
///
/// Returns a string defining the health of the service.
///
/// <returns>Either "Good", "Moderate" or "Critical"
public override string ServiceHealth()
{
return "Good";
}
I don't understand however why it's keep name value pairs between invocations, shouldn't you just be able to call a web service, have it do it's thing and then have it die until it's called again at which point it starts afresh or have I misunderstood how web services work? This is obviously a fairly simple example as all I'm doing is returning a string yet having problems, I put together a full blown webservice the other week that worked fine so can only assume this is to do with the inheritance and such.
Hope someone can help!
Regards,
Ian.
|
|
|
|
|
If that's the whole code for service, I don't see any problems so I'd guess that the problem is at calling side. How do you invoke the webmethod and discover the service?
|
|
|
|
|
Further investigation and I have to apologise, it was indeed nothing to do with those methods.
In the constructor I add some settings to a static dictionary and when the web service is called again the constructor is called again to add to the static dictionary.
I'm still a little unsure how web services work now then, is it the case then that all static classes remain between sessions and only the web service class themselves that are recreated each time a web service is called or something?
Is there anywhere that explains exactly what is and isn't created when a web service method is invoked and what is/isn't destroyed afterwards?
|
|
|
|
|
The basic idea is that app domains are separated, they cannot have common data. Inside an app domain you can share the data.
When you call a web service the first time, it's compiled and then executed inside an IIS process. After that the process dies if it's no longer called in a decent amount of time (which can be configured). However, if the process exists when the second call comes the worker thread from the process is taken to serve the call. Without seeing the code, this could be the reason why the dictionary is already filled.
|
|
|
|
|
Huston...
Ok, I commited to developing an application wrapper and, as usual, after delving into the nitty gritty, found out that the first guess wasn't quite right.
I have an intranet site which runs various reports, say 10 asp.net 1.1 pages.
I was asked to write a wrapper application around these reports, to provide default values to them, run them each in sequence and capture the output. The output is then sent via email to the report recipients.
ok, that's not too bad.
here's where my troubles start.
1. the site uses forms authentication;
so when a request is received for a page, i get redirected to a login page.
I've got to then parse the login page for viewstate variable, and manually submit the username and password back to the server to get a security token.
2. The reports use an asynchronous loading pattern similar to this site http://msdn.microsoft.com/en-us/magazine/cc163553.aspx[^]
where the initial page redirects the response to a wait page. the wait page then polls the original page continuously until the page has completed it's execution.
I've been scratching my head for about a week now.
I'd really appreciate any help on this.
Other than rewriting the reports one by one myself, I can't see what I can do.
Maybe I could manage step 1, with the login stuff, but I don't have a clue with issue #2
.
|
|
|
|
|
Is it possible to edit slightly the first application and provide a web service method to 'authenticate' you to the site, or something similar.
|
|
|
|
|
Hi,
I think I can get the authentication thing, it's just a bit messy, scraping response strings,
the real issue is in how to handle the async loading
|
|
|
|
|
Hi,
I want to access a public function declared in a content page from the master page.
I have a master page and a few content pages that have the same master page.On click of a button in the master page I want to call a function from the content page.All my content pages have the function with the same name...but they have different functionality based on the page.
I tried and I was successfull in accessing the content page controls properties from master page using below code.
Me.ContentPlaceHolder1.Page.FindControl("Button").Visible = False
Please let me know how to call a Content page function named "ValidateContent" from the master page.
Thanks in Advance.
modified on Thursday, December 4, 2008 9:48 AM
|
|
|
|
|
I think the best way to do this would be to create in interface which defines the function you want to call that your web forms implement:
<br />
public interface IContent<br />
{<br />
string ValidateContent();<br />
}<br />
then from your master page you can cast the child page as an IContent interface as return the appropriate value:
<br />
IContent child = (IContent)this.Page;<br />
Response.Write(child.ReturnValue());<br />
It definitely isn't definatley
|
|
|
|