|
Yeah, what they said. Personally, I'd do someting more like this:
this.filesList = new string [ filesList.Length ] ;
this.pathsList = new string [ filesList.Length ] ;
System.IO.FileInfo temp ;
for(int i=0; i<noOfFiles; i++)
{
temp = new System.IO.FileInfo ( filesList[i] ) ;
this.pathsList[i] = temp.FullName ;
this.filesList[i] = temp.Name ;
}
And more likely I'd use List<string> s rather than arrays.
I also pass file specifications through System.Environment.ExpandEnvironmentVariables before using them, but that's just me.
|
|
|
|
|
i had Created a Window Service which check the Update From the Server. Now the Issue i have is that if Update is Found on the Server then there is another application which is basically an updater. i want to Interact My Service with the My Desktop Application so that there is a pop up window of my desktop Application is shown which tell the client that update is available on the Server.
Can any body tell me that How can i interact my window service with desktop application.
wasim khan
|
|
|
|
|
You can use remoting or pipes for inter process communication.
Giorgi Dalakishvili
#region signature
my articles
#endregion
|
|
|
|
|
you can share a file that can be check both of your windows service application and desktop application periodically.
in windows service :
- check if shared update file is exist, if file is exist do not check update from server, otherwise check update from server, if update found create shared update file
in desktop application
-check if shared update file is exist, if file is exist pop up update information window, perform update, delete shared update file
hope it helps
dhaim
programming is a hobby that make some money as side effect
|
|
|
|
|
If you are running SQL Server 2005 have a look at Service Broker - its similar to MQ.
Bob
Ashfield Consultants Ltd
|
|
|
|
|
I need to create a web service to call a business logic class without using reflection. Can someone send me a sample
Thanks
|
|
|
|
|
heres a sample for you
public answerToQuestion TryToGetHelpFromCP(string question)
{
if(you.isLazy)
{
return new answerToQuestion("Flames Like This");
}
else
{
return CPiansConsiderQuestion(question);
}
}
Harvey Saayman - South Africa
Junior Developer
.Net, C#, SQL
you.suck = (you.passion != Programming)
|
|
|
|
|
Can the administrator block such kind of provocative replies please. Also the person who send it should be removed.
This suppose to be a serious site
|
|
|
|
|
Gktony wrote: This suppose to be a serious site
Then ask a serious question AFTER reading the guidelines [^]at the very top of the forum paying particular attention to point 2.
Dave
|
|
|
|
|
Gktony wrote: Can the administrator block such kind of provocative replies please.
And how would you suggest they do that? Delete the message maybe but block it all together?
Gktony wrote: Also the person who send it should be removed.
I have a name you know. and in my opinion YOU should be removed
Gktony wrote: This suppose to be a serious site
yes, its supposed to be... BUT you coming here demanding code for a very vague "question" isnt very serious! This is a FORUM where we discuss specific programming problems you might have come across. This is NOT some place where you can demand we do your work for you.
Gktony wrote: I need to create a web service to call a business logic class without using reflection. Can someone send me a sample
well congratulations, i need to write an application to calculate time and attendance data, but you dont see me asking people to do it for me. what have you tried? where are you having problems? have you heard of google? as my "joke code" implied if youre not willing to help yourself no one here will even bother to even try.
Harvey Saayman - South Africa
Junior Developer
.Net, C#, SQL
you.suck = (you.passion != Programming)
|
|
|
|
|
If you are not happy with the question there is a better way of putting it. Either ask to be more specific or ignore it (don’t bother as you mention). All of your writing is absolutely unnecessary and doesn’t help anyone.
The reason I didn’t provide any code is because I know is only a line or two of code and yes I have search the web for it prior to my posting.
I have got it working using reflection and I want to make it work without reflection.
The code I used is,
[WebMethod]
public object ExecuteMethod( object ClassName, string method, params object[] arguments)
{
object returnedObject = ClassName.Method();
return returnedObject;
}
The problem I have is how to invoke the class name and method parameter in the web service
|
|
|
|
|
Why is reflection such a no-no for you? The only other way I can think of is to dynamically create code to fire off this class/method. You would look to do this with the CodeDom.
|
|
|
|
|
Peter,
Thanks for you reply. I got it working using reflection but it creates security issues and I want to avoid that.
regards
|
|
|
|
|
Hi All...Can any1 tell me how to close my IE with a click event?
Thanks in advance
living life on the flip side
|
|
|
|
|
|
Hi Paw...thanks for the intelligent advice...it was genius to figure that out...
living life on the flip side
|
|
|
|
|
living life on the flip side
|
|
|
|
|
Use the click-Event handler of your ?button? and add the following lines of code
Response.Write("<script language="javascript">window.close();</script>");
hope this helps
Franz
|
|
|
|
|
Hi Franz,
wen i use the code then i get the following error:
Error parsing near '<div class="ForumSig">living life on the flip side</div>
|
|
|
|
|
don't use " - use ' instead
if this doesn't help - post the complete event-handler and I will have a look on it
franz
|
|
|
|
|
Hi Franz...this is the error i got:
Sys.WebForms.PageRequestManagerParserErrorException: The message recieved from the server could not be<br />
parsed. Common causes for this error are when the response is modified by calls to Response.Write(), response<br />
filters, HttpModules, or server trace is enabled<br />
Details: Error parsing near '<script language='ja'
living life on the flip side
|
|
|
|
|
|
Hi Paw...thanks but no luck...it still breaks...my above msg has the full error
living life on the flip side
|
|
|
|
|
The system complains because you are doing something very insecure. I think you can turn this off with PageValidation or something, but rather find another way. I suggest you try that in the Web or ASP.NET forum.
|
|
|
|
|
hi ,
use this in ur aspx page
<asp:linkbutton id="lnkClose" onclientclick="Javascript:window.close()" runat="server" text="Close" xmlns:asp="#unknown">
Ashok
|
|
|
|