|
hey anybody try to use MSHTML.ShowHTMLDialog?
or everybody using AxWebBrowser! 
|
|
|
|
|
osto wrote:
hey anybody try to use MSHTML.ShowHTMLDialog?
or everybody using AxWebBrowser!
Ok, whats your problem?
Mazy
"One who dives deep gets the pearls,the burning desire for realization brings the goal nearer." - Babuji
|
|
|
|
|
well i as wondering witch one as best for viewing a generated html report!
|
|
|
|
|
Whichever one you want. They are both hosts for MSHTML, but the Web Browser component (an RCW around the IWebBrowser2 implementation for IE) provides more services than MSHTML itself, such as hyperlink resolution and additional methods. Using the AxWebBrowser component (the actual class that's generated, which derives from AxHost ) also allows you to embed your report in a form, while using the ShowHTMLDialog helper API from MSHTML does not.
Microsoft MVP, Visual C#
My Articles
|
|
|
|
|
Is there a way to make Global Vaiables? Can I add them to the Application or ApplicationContext?
Stefan
|
|
|
|
|
U can use singleton class with public properties
Koby
|
|
|
|
|
Global variables are generally a sign of poorly thought out design. However there are cases when you want to make something available to classes across your application (like values from the application's config class).
I would suggest a couple of approaches:
1. Is to make the variable available through a static property of an appropriate class.
2. Is to make a class (a singleton) that exposes these values through static properties. For instance a Config class that retrieves the information from a config file and exposes them to the rest of the application.
"You can have everything in life you want if you will just help enough other people get what they want." --Zig Ziglar
Coming soon: The Second EuroCPian Event
|
|
|
|
|
Hi
I have MFC Dll with dialog, I used it in C# App.
It's working functionality, but
The MFC Dialog stays grey. (Missing WM_PAINT (?
I think that I have problem with window handle.
Can U help me?
Thanks
Koby
|
|
|
|
|
|
Can you give us a code fragment of how your C# code invokes the MFC built dialog/control? There are plenty of things that can go wrong. Without more information its purely conjecture on what to do to fix it.
|
|
|
|
|
The Code in the C#:
[..."MyDll.dll"...]
export static int Init(CallBack* xxx, SData* ps);
The function get delegate to return event from the DLL and data on the application. ( name and ID, not window handle or other data like it)
Koby
|
|
|
|
|
why are you using win32 for a dialog box anyway?
show us WndProc and the one that create the dialog!
|
|
|
|
|
Sorry I forgot an essential point.
All the function (from App to the Dll ) was at other Thread ("Dll thread").
Not in the main (GUI) thread, but in the same one (using queue)
The init(…) and other function first enter to Q and the pulled by the "Dll Thread")
koby
|
|
|
|
|
hello,
i've got a small problem right now. i started developing a small toolbar for my personal use which is docked at the top of the desktop. now i want to change the workingarea of the desktop, so other window forms cannot overlap my toolbar.
i would be thankful for every solution.
thx a lot
|
|
|
|
|
|
If you're not using a desk band (an "explorer band" is also a desk band, BTW) and instead simulating your bar being docked in the desktop, then you're close to using an app bar, which the task bar is, as well as the old Office shortcut bar. See the article, C# does Shell, Part 3[^], which discusses app bars using C#.
Microsoft MVP, Visual C#
My Articles
|
|
|
|
|
Hi!
Is it possible to format a string so that a certain part will be displayed as subscript text?
For example a label displays the string "n1 + n2 =" and "1" and "2" should be subscript.
I searched through the documentation but must have missed it, at least i hope so
THX in advance
|
|
|
|
|
There are several ways. One is through markup like with HTML that uses the <sup> and <sub> tags. I doubt that's appropriate here, however.
Another is to get a font that is full of these. It's not uncommon to have a font represent symbols. Microsoft uses several fonts for glyphs in Outlook and other applications.
Since .NET supports Unicode, there is the superscript and subscript diacritics in the U+2070 through U+209F range. The problem is that you need a font that supports them. Tahoma (default font) and Arial Unicode MS currently do not, nor do any of the other common ones. If you had a font that supported this Unicode range and displayed the text in a TextBox (for example), then you could use:
"n\u2081 + n\u2082 =" Finally, about your only other option is to owner-draw the text yourself in parts using Graphics.DrawString and either off-setting the coordinates of the upper-left corner or using a StringFormat with a LineAlignment set accordingly.
Microsoft MVP, Visual C#
My Articles
|
|
|
|
|
hi
I wrote a client/server windows application`s
and sending data by convert it into byte`s
NOW
**********
I need to send xml bitween them
if any one has a code to do that please send it to my
thank you for all
|
|
|
|
|
Just use the Encoding class to get the bytes for XML using whatever encoding you want, send the bytes, then use the same Encoding class on the server to get the XML from the bytes. I'd recommend a UnicodeEncoding to allow for the full range of characters.
Microsoft MVP, Visual C#
My Articles
|
|
|
|
|
thank you Heath Stewart
but i know this way and i need to send as xml not by encoding
thank you again
|
|
|
|
|
Everything - even text files like XML - is still just an array of bytes. You must Encode before transmitting it across the wire. Even every web page, Web Service, etc. do that. What do you think the second clause of the Content-Type header (if there) or the Content-Encoding header is? That just the way it works.
Microsoft MVP, Visual C#
My Articles
|
|
|
|
|
Is it possible to show a window form as the child of another window form in an SDI application? It was possible in VC++ 6.0 to show a dialog box as the child of another dialog box such as in property sheets. What I wanna know is that is this possible in C# also?
Its very urgent, any help will be greatly appreciated.
Thx in advance
Gurmeet S. Kochar If you believe in God, it's because of the Devil
My CodeProject Articles: HTML Reader C++ Class Library, Numeric Edit Control
|
|
|
|
|
FormName.ShowDialog(this);
I'm not sure if this is what you are trying to achieve. If you want the child window to be contained within the frame of the parent window, I'd suggest either using mdi or putting your child window on a user control and adding it to your parent window's controls.
|
|
|
|
|