|
hello,
I have to open web page with address bar, specified width, Height from window forms without using
WebBrowser control.
help is appriciated
|
|
|
|
|
Then how are you going to show the page??
Without the WebBrowser control you'll have to implement your own rendering engine. Good luck with that!
|
|
|
|
|
Dave Kreskowiak wrote: Good luck with that!
Wheres that dammed sarcasm smiley!
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
vikaskardode wrote: without using
WebBrowser control
Enjoy
Bastard Programmer from Hell
if you can't read my code, try converting it here[^]
|
|
|
|
|
In back-and-forths with this poster on QA in this thread:[^]:
I am left with the idea about writing perhaps three articles, aimed at relative beginners with WinForms, showing how to use inheritance to create Forms that essentially duplicate an existing Form (where, for example, you want a set of standard identical controls with identical behaviors on every Form created).
Second, I would like to discuss the shortcomings of that approach when you, for example, wish one Form that inherits from a "master Form" to not have one of the inherited controls (which in the designer appear "locked" when: you create a new Form, add it to the Project, and then make it inherit from the "master Form.")
Third, I'd like to compare the strategy of switching between identically sized and positioned Forms to vary the user interface (which is what the OP of the QA post linked to above was after), vs. the simpler strategy of using Panels which are switched at run-time on one Form (but where said Panels may also use inheritance in the same way as described above with Forms).
My question is: given the possibility that WinForms is now no longer of that much interest to CP members compared to the latest "hot stuff:" is it really worthwhile to write this up, and include tricks like use of a static class to manage multiple Forms, or Panels, or modifying the Program.cs class to call an 'Initialize method in a static class, etc.
thanks, Bill
The glyphs you are reading now: are place-holders signifying the total absence of a signature.
|
|
|
|
|
I don't see any harm in doing this even though WinForms is not as hot as new technology with .NET, but you never know when someone might have a need for it and an article would be useful for them.
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
BillWoodruff wrote: WinForms is now no longer of that much interest to CP members
I get the impression there are still lots of CPians using this technology, and will be for a good few years to come. If you think the article(s) would be useful then give it a go.
|
|
|
|
|
BillWoodruff wrote: is it really worthwhile to write this up
Yes, it is. Not every shop uses WPF, a lot of them still build on the controls that they and their customers are familiar with. I'm still using WinForms as WPF isn't implemented in Linux. Yes, Gtk# might be an alternative, but that would introduce a learning-curve for anyone unfamiliar with Gtk#.
Bastard Programmer from Hell
if you can't read my code, try converting it here[^]
|
|
|
|
|
i want to display large content i.e data may be 50 to 60 mb for example bible in desktop application.how i can do that?
|
|
|
|
|
What format is the data in?
Where is you data stored?
How do you want to retrieve it?
The simple answer is:
Write a program to to retrieve the data and display it in an appropriate control.
And the answer is just as useless as the question!
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
Mycroft Holmes wrote: And the answer is just as useless as the question!
But gets a 5 for trying.
|
|
|
|
|
Hai Lee Paul Alexander,
I am using your superlist control in my application. Can you please suggest me how to update,delete and add rows when it is binded through datatable.
However the binding is happening by creating a custom datatable and custom datarow. No i do not know how to update, delete and add rows in the control which will reflect in the database.
Thanks in Advance,
Rajesh
|
|
|
|
|
If you have a question about something you found in one of the articles, you should ask the question in the forum at the end of that article. It's very, very unlikely that Lee Paul Alexander will happen on the question in a none related forum, whereas he gets an email if you ask on that article.
|
|
|
|
|
Hai,
When I am trying to bind datatable to a superlist control it is throwing an error "Failed to compare two values in an array". Can any one help me on this issue.
|
|
|
|
|
I already did, and you didn't take the effort to respond. Are you expecting a different answer today?
Bastard Programmer from Hell
|
|
|
|
|
Hai,
I am trying to bind datatable to the superlist control.But it is throwing an error "Failed to compare two elements in the array."
Can anybody please help me on this.....
|
|
|
|
|
Kandepu Rajesh wrote: Failed to compare two elements in the array
Wrap your array in an object that looks like the ActiveRecord-pattern, and implement IComparable.
The control you're referring to isn't part of the .NET Framework. If you need further help, I suggest you contact the author.
Bastard Programmer from Hell
|
|
|
|
|
Hai,
I am trying to bind datatable to the superlist control.But it is throwing an error "Failed to compare two elements in the array."
Can anybody please help me on this.....
|
|
|
|
|
Superlist? WHAT Superlist? It's not part of the .NET Framework, at least not with that name.
|
|
|
|
|
Actually..the superlist control is not a .net framework control.It is user control developed and posted by Lee-Paul-Alexander..
The below is the link for his profile..
http://www.codeproject.com/Members/Lee-Paul-Alexander
Can you please go through the control and give me a solution on how to bind datatable to teh control..
|
|
|
|
|
I don't have the time to go spelunking through that code and adding/fixing support for binding.
If you've got a question, post it in the forum at the bottom of the article.
|
|
|
|
|
Below is the code that is actually closing the whole application when clicked on Yes.
But,I want to close the current form and open the new form when the user clicks on X with red mark i.e. close on the form.The code I wrote is :
<pre lang="vb">Private Sub form1_FormClosing(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles Me.FormClosing
Dim response As MsgBoxResult
response = MsgBox("Do you want to close?", MsgBoxStyle.Question + MsgBoxStyle.YesNo, "confirm")
If response = MsgBoxResult.Yes Then
Me.Dispose()
homepage.Show()
Else
If response = MsgBoxResult.No Then
e.Cancel = True
End If
End If</pre>
end sub
|
|
|
|
|
- The code is using language-elements from VB6. You should use the
MessageBox class.
- WinForms don't have a homepage, they got a MainForm. You open other forms from there, and when you close them, you'll see the mainform again.
- FormClosing should only check whether the current form can close, it should not be calling the mainform (nor the homepage)
- I'd suggest to pick up a good book on C# - it would help in understanding VB.NET and would keep you away from VB6-legacy code.
Hope this helps
Bastard Programmer from Hell
|
|
|
|
|
I have a button in my form and on click of that button I am writing this code....
OdbcCommand cmd ;
cmd = new OdbcCommand(abc, cn);
cmd.CommandType = CommandType.StoredProcedure;
cmd.ExecuteNonQuery();
I have made a procedure named abc in database which is returning only one row from login table..So i am just checking that on click of that button my procedure should run but while debugging when i come to cmd.ExecuteQuery() it throws following error..
ERROR [42000] [MySQL][ODBC 5.1 Driver][mysqld-5.0.77-community-nt]You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'abc()' at line 1.
So plz tell me what would be the problem..
|
|
|
|
|
Please stop spamming the forums with this same question[^]. You have been given suggestions about resolving this, go and try some of them.
|
|
|
|