|
Could any one tell me how to maximize a form within a web project in C#?
I cannot find a direct way to do this unless it is a traditional Windows application where you simply code something like "MyForm.Maximize = true;".
Thanks.
William
|
|
|
|
|
Because you're working within a web page and are subject to the object model exposed by the browser (and you're limited in what you can do anyway). You can either add some client-side JavaScript to the page that uses the screen object or open a popup window using window.open that specifies the initial settings (which you get from the screen object). All major browsers expose such an object (it is part of the HTML DOM, after all).
If you need additional help, please ask in the Web Development[^] forum. With client-side scripting, this has nothing to do with C# (which is a managed language you would find either in an ASP.NET server application that simply constructs client-side HTML, JavaScript, images, etc.) or in a Windows Forms control to be hosted in an HTML page (like an ActiveX control).
This posting is provided "AS IS" with no warranties, and confers no rights.
Software Design Engineer
Developer Division Sustained Engineering
Microsoft
[My Articles] [My Blog]
|
|
|
|
|
Hello,
I have been looking for the answer for this but haven't seen anything clear.
I am new to c# and want to create a sorted list (or a collection with key/object) with the key as a string and the second element a class object that i have created. But this doesn't seem to work directly (I'm used to STL in c++).
It appears I have to do some work with this class object. Can someone point me to a place where this is properly described?
Thanks in advance, jb
===================================
jonathan borden
jrborden@austin.rr.com
|
|
|
|
|
|
Hi,
I have a TIMER and a WebBrowser component.
When the program goes to the System Tray and Timer Refreshs the WebBrowser Component ( i cant see the program form, normal), i loose the focus of my active window
How can i fix this?
|
|
|
|
|
The WebBrowser control - an ActiveX control that is hosted through an RCW, or Runtime-Callable Wrapper - is subject to its own focus handling. Either the AxHost (the base class for the AxWebBrowser class) has the focus or it doesn't, but how the WebBrowser control itself maintains focus is completely independent of .NET. IT could, for example, have the focus while the AxHost doesn't even realize it has the focus. This is a common problem (not just with the WebBrowser control, but with all ActiveX controls hosted in .NET).
Once way of solving the problem is to get the handle of the currently active window before you refresh the WebBrowser and then restore it. For this, you'll need to P/Invoke the native GetForegroundWindow and SetForegroundWindow APIs. If you need help declaring the P/Invoke signatures, see http://pinvoke.net[^].
To solve the problem with the WebBrowser control itself, you either need to correctly identify the container (this gets deep into COM interfaces, so experience in this area is helpful; there are some articles on this site that may help if you search for "WebBrowser", for example) or to make sure that the WebBrowser control never takes the focus to begin with. One way - and this is untested but should work - is to set the WebBrowser.Visible property (not the inheritted AxHost.Visible property!) to false . IF correctly implemented, the control should not try to steal the focus if it is not even visible.
This posting is provided "AS IS" with no warranties, and confers no rights.
Software Design Engineer
Developer Division Sustained Engineering
Microsoft
[My Articles] [My Blog]
|
|
|
|
|
hi,i am a new bee in this group.
i need the c# code for backpropogation using neural networks in artificial intelligence.sorry for the confusion.if any of u got it then pleasw send mail me.
thanx a lot
kasi malla
|
|
|
|
|
You might define what you mean by "backpropogation" first. I've never seen such a word used in any context.
This posting is provided "AS IS" with no warranties, and confers no rights.
Software Design Engineer
Developer Division Sustained Engineering
Microsoft
[My Articles] [My Blog]
|
|
|
|
|
Heath Stewart wrote:
backpropogation
I'm guessing the OP means undo (and possibly redo) functionality. If so start your search with "GOF Command Pattern".
|
|
|
|
|
are you talking about neural net's?
IM PROUD TO BE A GMAIL;
|
|
|
|
|
I'm trying to achieve something similar to a VS.Net 2003 IDE where there is an option when you hover your mouse over, it slides out (If you set auto-hide enabled). Did anyone here have a sample code of how to achieve that ? Or guide me in the right direction ?
Stanley
|
|
|
|
|
Hi,Sir and Madam
Please give ma an idea about "word cutting" (not English).
Some language (such as Thai) a sentence has contigugous words and sentences separated by space while English a word separated by space and sentences separated by (,) and (.)
Example:
ยินดีต้อนรับทุกคน = Every one is welcome.
Sorry for bad English.
Thank You.
|
|
|
|
|
Try a search on word stemming[^].
This posting is provided "AS IS" with no warranties, and confers no rights.
Software Design Engineer
Developer Division Sustained Engineering
Microsoft
[My Articles] [My Blog]
|
|
|
|
|
depending solely on web MSDN is not enough for me....
anywhere I can download?
thanks, all
dennis
|
|
|
|
|
The place to start would be on the web site you apparently so often visit: http://msdn.microsoft.com[^]. You should see Subscriptions[^] right there at the top. A little digging should turn up the MSDN Library Subscription[^]. It is definitely worth it and integrates fully with VS.NET (installing both into the VS Combined Collection as well as a stand-alone collection that VS.NET can reference directly; I prefer the Combined Collection in order to incorporate any third-party libraries).
This posting is provided "AS IS" with no warranties, and confers no rights.
Software Design Engineer
Developer Division Sustained Engineering
Microsoft
[My Articles] [My Blog]
|
|
|
|
|
im using .net and how would you reverse the contents of a file so if
1
2
3
4
would be a file how would i write
4
3
2
1
???
thanks
IM PROUD TO BE A GMAIL;
|
|
|
|
|
StreamReader sr = new StreamReader(filename);
string t1, t2;
while ((t1=sr.ReadLine()) != null) {
t2+= t1+"\x1D";
}
string[] tsa = t2.Split('\x1D');
sr.Close();
StreamWriter sw = new StreamWriter(filename);
for (int i = tsa.Length-1; i >=0; i --) {
sw.WriteLine(tsa[i]);
}
Hope it'll help...
Robin Panther
|
|
|
|
|
thanks by the way whats \x1D?
IM PROUD TO BE A GMAIL;
|
|
|
|
|
I'm currently using an async web service in a client I'm writing. I started using synchronous calls but that turned out to be too time-consuming, blocked the UI and it was impossible to display any kind of progressbar/waiting message. Anyway, using async calls works great, but if the web service in question throws an exception, I'm out of luck since I don't know how to handle the exception.
Any suggestions/hints?
Best regards,
Daniel
Wenn ist das Nunstück git und Slotermeyer? Ja! Beierhund das oder die Flipperwaldt gersput!
|
|
|
|
|
The "easy way out" is to handle the AppDomain.UnhandledException event using AppDomain.CurrentDomain . This allows you to - as the event is aptly named - handle exceptions that were not explicitly handled.
The correct way is to do a little debugging. That's just part of development. Off hand, I'd say that your callback method - if you declared one - would catch such an exception. A SoapException is, after all, just another response that is formatted differently. The exception would also most likely be thrown from the thread and in the method where you called BeginMethod .
This posting is provided "AS IS" with no warranties, and confers no rights.
Software Design Engineer
Developer Division Sustained Engineering
Microsoft
[My Articles] [My Blog]
|
|
|
|
|
Thanks, I wasn't aware of the AppDomain.UnhandledException event, and although I won't use it for this particular problem (I'll go for Daniel Turini's solution, see below) I'll definitely make use of this newfound knowledge in the near future
Wenn ist das Nunstück git und Slotermeyer? Ja! Beierhund das oder die Flipperwaldt gersput!
|
|
|
|
|
I did mention to debug your code and try it out. Were you not calling the EndMethod event before? Using either callbacks or the EndMethod - if you care about any returns values, exceptions, etc. - is necessary. Otherwise you're just aysnchronously invoking a method and won't get a return back. For methods like logging methods, this may not matter but for methods like Add(int, int) you would certainly want the return value back.
This posting is provided "AS IS" with no warranties, and confers no rights.
Software Design Engineer
Developer Division Sustained Engineering
Microsoft
[My Articles] [My Blog]
|
|
|
|
|
dabs wrote:
ut if the web service in question throws an exception, I'm out of luck since I don't know how to handle the exception.
If the web service throws an exception, the End* methods will throw it, and you can handle it there.
Yes, even I am blogging now!
|
|
|
|
|
Thanks, wasn't aware of this fact. Sounds like the correct place to catch those exceptions so that is what I'm gonna do.
Wenn ist das Nunstück git und Slotermeyer? Ja! Beierhund das oder die Flipperwaldt gersput!
|
|
|
|
|
i already did the columns for the controls but i don't know how to add different items under the same row like how would you do
something | something | something
----------+-----------+----------
123 |123 |123
i would appreciate the help thanks;)
IM PROUD TO BE A GMAIL;
|
|
|
|