473,804 Members | 2,028 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

VB 6/.NET Code on 2003 Server won't print html file from WebBrowser or axDHTMLEDLib

12 New Member
I have code that works fine on my XP machine. It loads an HTML document into the VB 6 WebBrowser control and then uses the following command to print the document without any print dialog box:

mfrmPrint.WebBr owser1.ExecWB OLECMDID_PRINT, OLECMDEXECOPT_D ONTPROMPTUSER, PRINT_DONTBOTHE RUSER_WAITFORCO MPLETION

I have also just implemented a .NET C# DLL that uses the axDHTMLEDLib. It also works fine on my XP computer.

It seems like a simple IE or machine configuration problem. When I open the Internet Explorer 6 browser, the following message is displayed.

Internet Explorer Enhanced Security Configuration is enabled

I have tried removing this (apparently some present IE security settings) and it didn't do the trick.

Thanks for any ideas.
Aug 10 '09 #1
4 2932
Plater
7,872 Recognized Expert Expert
Does your server have the vbrun6.dll? Is there a benefit to not using the .NET webbrowser control in favor of the vb6 control?
Aug 10 '09 #2
ems9tech
12 New Member
Various VB 6 programs are running fine on the server. I put the code in VB 6 because there seemed to be more examples of working WebBrowser code. I could try doing it in .NET, but I still think the problem isn't the code but some configuration on the Windows 2003 Server...
Aug 11 '09 #3
ems9tech
12 New Member
I get no errors, but nothing is sent to the Printer Queue (I have it paused so I'm sure).

I did disable Enhanced Security, but no change. I have had an issue in the past with this code getting errors and fixed it by reinstalling IE 6 using method 3 in this MS article:

How to reinstall or repair Internet Explorer in Windows Vista and Windows XP

I just discovered that the Server has IE 7 installed and I have IE 6 on my XP machine (It also works on a co-worker's XP with IE 6 machine). I believe the issue is with IE 7 and probably specifically it's security.

I have tried all of the suggestions I could get from this article to no avail (even re-booted after making the registry changes):

Visual Basic 6 And Internet Explorer 7

Added the following to Trusted Sites: IP Address of Printer Port

I think my solution may just be to uninstall IE 7 and install IE 6... :~(
Aug 13 '09 #4
ems9tech
12 New Member
Does it make any difference that the 2003 Server is also a VMware environment?
Aug 27 '09 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

3
4234
by: Hasani | last post by:
I tried using webBrowser.ExecWB(SHDocVw.OLECMDID.OLECMDID_PRINT, SHDocVw.OLECMDEXECOPT.OLECMDEXECOPT_PROMPTUSER) but it returns asynchronously. Is there anyway I can know when the document has finished printing when using webBrowser.ExecWB ? I also tried using rundll32.exe with mshtml.dll but again it displays a dialog. So my question to that is, how do I print using rundll32.exe w/ mshtml but not have it display the print...
19
3996
by: Mark Gross | last post by:
I am attempting to programatically drive a Lotus Notes web application from a VB.NET database application (who wants to rekey information in one database into someone else's web page for entry to theirs?). I am using the System.Net.WebClient to communicate with the LotusNotes server. It is not clear if I should be instantiating a new object for each communication, or persisting the initial one. based on the input values in the web...
0
2263
by: Thara DK | last post by:
i have the Following method to Print an Html frames and if i ran this method through a loop i get the follwing error.... Sub PrintFrame(toFrame, tnPrintOption) Dim loWebBrowser toFrame.focus If Not IsNumeric(tnPrintOption) OR tnPrintOption < 0 OR tnPrintOption > 3 OR tnPrintOption = "" Then tnPrintOption = 0
15
4650
by: Cheryl Langdon | last post by:
Hello everyone, This is my first attempt at getting help in this manner. Please forgive me if this is an inappropriate request. I suddenly find myself in urgent need of instruction on how to communicate with a MySQL database table on a web server, from inside of my company's Access-VBA application. I know VBA pretty well but have never before needed to do this HTTP/XML/MySQL type functions.
24
1539
by: Skijor | last post by:
I have inherited a php script that nests php, javascript, and html. How do I clean up code like this: I think I can move the javascript into a seperate .js file at the least. What about the nesting of php inside the html? <?php ....snip... function ShowCart()
2
4056
by: hup | last post by:
One of my Linux (CentOS) server stop interpret php code any more. I did try to compile and installed other version of php, but it's still not working. # cat /tmp/phpinfo.php <? phpinfo() ?> # /usr/local/bin/php -v
6
1727
by: Just Me | last post by:
Any ideas on this. I am trying to loop through an xml document to remove attributes, but Im having so much trouble, any help is appreciated //THIS IS THE EXCEPTION ( SEE CODE LINE WHERE FAILURE OCCURS '//Unexpected XML declaration. The XML declaration must be the first node in the document, and no white space characters are allowed to appear before it. Line 13, position 11. //THE XHTML TEXT WHICH IS BEING LOOOKED AT
3
2139
by: Nordiek, Christof | last post by:
I have an applaction, that is an addin for Outlook. It opens a form with a WebBrowser control wich then shows a page from a Webserver. It works fine, but when I installed it on Windows Server 2003 the page didn't get shown in the WebBrowser control. I have another application wich uses the same form, but is a standalone Winform-Application. This works on both machines (my development PC with Vista and the Windows Server 2003. Does...
2
7602
by: Artie | last post by:
Hi, I've searched the web but can't find a solution to an apparently really simple problem. My app contains an HTML string and I need to be able to invoke the Print Dialog to print the HTML correctly formatted (i.e. not as raw HTML) to a printer that the User chooses. So, I need something like:
0
9711
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9593
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10343
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10335
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10088
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9169
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7633
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5668
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4306
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.