|
Why bother to post that when I already answered him ?
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
void JSAlert(string strMessage)
{
this.Page.RegisterClientScriptBlock("","<script type='text/javascript'>window.onload = function(){alert('"+ strMessage +"')}</script>");
}
and call this method wherever u need with the message as parameter.
Cheers
Bino
www.codepal.co.in
|
|
|
|
|
I have an application (Application A) which will launch another application (Application B) by passing some arguments in same machine.
One of the argument is language use in Application A.
When Application A run in Italian.lang, then Application B will launched in Italian.lang as well.
Now, if Application A change language to English.lang, then running Application B need to change language to English as well. So i decide to use some inter-process communication method to solve this problem. I have limited time to do this changes.
Application A will send notice to Application B when change language.
Application B just need to listen to Application A.
If possible i would like to have 2 way communication to adapt future change request.
What method is suit with my project? Pipe or socket? Or any other method suit for it?
|
|
|
|
|
Go for sockets. Use TCPListener and do TCP communication.
|
|
|
|
|
A quick suggestion here would be to use windows messaging. The SendMessage API in windows..But for this you need to know the windows handle..Since it is in a same machine .. this technique will be the easest and light weight way. than going for tcp
http://www.codeproject.com/KB/dotnet/VB6andVBNETWindowMessages.aspx[^]
modified on Friday, February 27, 2009 2:34 AM
|
|
|
|
|
I would suggest a different approach, as it is obvious that TCP channels are wasteful when the two applications run on the same machine.
There's an article I wrote which explains how to do IPC in C#.
It's not the main purpose of the article, but you can use it to get ideas...
It's called A Pure .NET Single Instancing Solution[^]
Good luck...
Shy.
|
|
|
|
|
Thanks a lot.
It is the best solution that i found. I will try on it later when i finish other feature.Thanks.
Regards,
PeiYang
|
|
|
|
|
Hi,
I need to do drap and drop in virtual mode.
1. I use virtual mode to display large number of contact in icon view in my application.
Currently my application need to support drag and drop. I can't found any solution. Is that anyway to do so?
2. If i want to drag and drop a list to any location (not align to grid), how can i implement it?
Hope some one can help me to solve this problem. If can provide me some example to refer.
Thanks.
Regards,
PeiYang
|
|
|
|
|
I need some help in the final year project.Can somebody give me the idea of dynamic content generation in C#.
Can somebody also tell me how to search a topic from a book which is in RDF format and generating a book(here by book, i mean definition, explanation and exmaples...) of the topic i am searching. The algorithm i am working on should perform following steps:
1 Parsing the file(RDF)
2 Forming Semantic structure(graph)
3.On the basis of some reordering algorithm, generating the text out of the graph
Can you please guide me how to perform these steps in C#.Please help me....
|
|
|
|
|
Sounds like a lot of work. You have a year to get this done tho, right ? So, start by doing some research on the RDF format, and then consider how to turn that data into something you can build a graph from.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
Hi,
I am trying to complie using devc++. I have error on this line :
FILE * d , * m , * fopen();
any help?
Thanks
|
|
|
|
|
I think you posted in the wrong forum, this is C#.
And its probably because you cant have the function fopen() as a variable.
I'm also not so sure you can make pointers on the same line like that either, but I've never tried.
My current favourite word is: Delicious!
-SK Genius
Game Programming articles start - here[ ^]-
|
|
|
|
|
Adam_Omer wrote: any help?
Yes: buy a Sat Nav.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
|
mobius111001 wrote: I want to create a COM object that I will expose to 3rd parties.
Hum, interesting... What has it to do with the C# forum?
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
Where else should it go? Does it count I'm writing the COM object in C#?
|
|
|
|
|
mobius111001 wrote: Does it count I'm writing the COM object in C#?
Yes, indeed: you lost 100 man points for doing it that way.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
CPallini wrote: What has it to do with the C# forum?
He can't tell you that silly, you don't have proper security clearance.
|
|
|
|
|
You guys are evil. Funny as hell, but evil nevertheless
|
|
|
|
|
Did you seem my reply in the ASP.NET forum?
|
|
|
|
|
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
Do they requirements specify how strong the encryption needs to be?
The requirements are unrealistic. It is in fact impossible without relying on user input*. You can use encryption of course, but it will not do anything besides wasting valuable resources. It will bar only the worst pseudo cracker that dares call himself/herself a cracker - and those are not the people that the company should be concerned about.
It's impossible because this is not a communication-channel you're trying to protect (where evil Eve only has knowledge about the communication itself), this amounts to trying to protect static data. It's impossible. Even if 3rd party programs have to use a "secret" key. They key is not secret, because the 3rd party program can access it. Thus, so can anyone who has the 3rd party program. Even if it has to, for example, use yet an other key to decrypt the real key. Or a 3rd key to decrypt the 2nd key. Somewhere it will end in a piece of data that is readily available to anyone.
That leaves you with user input - that is, requiring that 3rd party software do not store the key inside itself, but asks the user to input it. Sure the users could leak it, but at least the data itself doesn't contain its own key.
However, and this is a much bigger problem, the very thing you're trying to protect with such heavy locks is still unprotected. That is, to use it directly requires opening the locks.. but what's to keep anyone from dumping the locks? Decompile(.NET - obfuscators will not stop real crackers)/disassemble(native) the dll, delete the encryption code, and recompile/re-assemble..
The only people you'd successfully protect from, are people from which you have little to fear.
|
|
|
|
|
Hi all,
I am having a little trouble with Regex.
Basically i have a text file that i am trying to parse.
In this file i know there will be a number of names, these names will always use 100 bytes of space, if the name, in plain ASCII code, is less then 100 bytes the remainder of the space is filed with 0xFF
My regex code is as follows.
streamreader sr = new streamreader("file.txt");
string text = sr.ReadToEnd();
sr.close();
string pattern = @"[A-Za-z0-9]|\xFF{100}";
Regex = new Regex(pattern);
foreach(Match match in Regex.Matches(text))
{
}
I think the problem is with the \xFF part of the program, as a simple regex expression such as @"\xFF" returns no where near as many 0xFF values as are present in the file
Thanks for any help
If only MySelf.Visible was more than just a getter...
A person can produce over 5 times there own body weight in excrement each year... please re-read your questions before posting
|
|
|
|
|
How about something like:
@"[A-Za-z0-9\xFF]{100}";
(Untested)
And about whitespace?
|
|
|
|
|
thanks for your reply,
I have tried your suggestion too and get the same results. white space characters in addition to basic symbols may be present but for now im just looking to get this one working as i am certain the HEX value is what is causing me problems
If only MySelf.Visible was more than just a getter...
A person can produce over 5 times there own body weight in excrement each year... please re-read your questions before posting
|
|
|
|