ActiveX Blocking Functions Freezing The UI

Aug 27, 2010

Is there a way to include an ActiveX to VB .NET project without adding it to a form?

If I add it to the form and call a function on it that blocks, the UI is unresponsive until the function returns. Even if I am making the call in a different thread.

I was able to compile the code when I did not include it via the form, but got this error once I called a function on it.

Catastrophic failure (Exception from HRESULT: 0x8000FFFF (E_UNEXPECTED))

How could I make the UI responsive when the ActiveX functions are blocking?

View 7 Replies


ADVERTISEMENT

IE Freezing While Accessing ActiveX?

Apr 4, 2009

Lets discuss about those created active x which got created in VB6 and not working in Vista.Here i will let you know my problem,no idea wheather we need to upgrade any runtime file in VB6 or in vista?

I have done an ActiveX to get client MAC address as its major part and runs over IE.it is successfully running in Win2000, Win2003, WinXp and even with IE7 with previously mentioned Window versions.

This ActiveX was developed in VB 6.0.

This ActiveX gets installed atomatically through a cab file, whenever the application was accessed first time.

this cab file work fine in WinXP but when we try to run this cab file in vista IE get hang

Now, we have to support it with IE7 over Vista.

let me know what should I do to make it compatible with IE7 and Vista. I am using Vista Business right now.

When the application was accessed through IE7 for the first time, ActiveX installation dialog appeared. I pressed the Install button but then IE7 threw an error message that "Internet Explorer has stopped working". After that each time, whenever the application was accessed IE7 threw the same error message.

Cab file i made in VB6 using internet and deploy package wizard,along with cab file we will get one HTM file also to get Object id and code base along with version,even if we try to open this HTM file then also IE get hang.

I tested by manually registering the ocx, also turned off the Protected Mode and enabled my ActiveX through Manage Ad-on as well, but to no avail.

View 1 Replies

Asp.net - Legacy ActiveX Control Calls DLL Functions?

Sep 1, 2010

Hint: this one might sound complicated, because I am trying to give as much info as possible, but I suspect that I just want someone to tell me "yes, you are correct".On this legacy system, which dates from 2002, the user visits a web page and uses an RFID reader to read a tag number, which is then written to an input field on the web page.

The only s/w that comes with the reader is a custom DLL, nop .exe. The very sparse documentation insists that only MSIE be used and that all security relating to ActiveX be disabled.When I look into the source of the web page I see calls to functions in the DLL.Now, here's the fun part: I know zilch about ActiveX, I have to make a minor change to the DLL _but_ the VB6 source code has been lost, so I guess that I have to recreate the (seemingly very simple) DLL from scratch - this week.

Decompiling the DLL shows me the functions (locateReader, getTagVal, closeReader). However, by decompiling I can't really know the number or type of the parameters, nor the return values ... and if anyone knows the API they are refusing to share it, but basically it all seems to have been lost in the mists of time as companies went bust, were bought & sold, merged & demerged and the initial DLL might have been written by an external guy, but no one knows who.So, can I get the function params & type from the ASP page source?I see things like

Reader = new ActiveXObject("<dllName>.Reader");
Reader.locateReader();
tagVal = Reader.getTagVal();
Reader.closeReader();

I would say that none of the fn()s take parameters, that closeReader doesn't have to return anything; it looks like locateReader doesn't return anything either, so I guess that error handling will have to be in the DLL (loop forever with a popup demanding that a reader be attached; and getTagVal seems to return a string.

View 1 Replies

Failed To Import ActiveX Control (trying To Load A VC++ ActiveX Component Into A VB Project)?

Apr 8, 2009

I am trying to load an actixex component in a VB project which was made in Visual C++.n VBA it works fine.In VB6, when I try to load the component on the toolbox I get an "Error 35005"In VB2008 the component can be added to the toolbox, but when I try to place it on the form, the following error occurs: "Failed to import ActiveX control. Please ensure it is properly registered."

View 1 Replies

Non-modal Forms Cannot Be Displayed In This Host Application From An ActiveX DLL, ActiveX Control, Or Property Page?

Oct 20, 2010

How to Resolve following Error in .netNon-modal forms cannot be displayed in this host application from an ActiveX DLL, ActiveX Control, or Property Page.

View 1 Replies

VS 2008 : Have A Class Where The Functions Of The Same Name Are Both Instance Functions And Shared Functions?

Dec 6, 2010

What I am trying to do is have a class where the functions of the same name are both instance functions and shared functions.

Public Shared Function Get...(byval xx as xx)

and

Public Function Get...

The Public Function uses a Property xx created in the constructor, whereas the Shared Function has the parameters (byval xx as xx).

View 1 Replies

Excel Maths Functions And Calls To All DLL Functions Documentation?

Jan 29, 2007

1) Is it possible to access the Excel mathematical functions without actually opening Excel?

I was thinking of through a DLL WinAPI call or maybe a delegate function or smaller program?

2) Does anyone know of a MS link or area that gives instruction on "how to" use every function of every Windows DLL at all?

Or for all those that Microsoft have chosen to document online at least.

View 1 Replies

Blocking A Website Through I.E?

May 4, 2010

I was wondering if it would be possible to block a website, such as "www.proxy.com"
Through Internet Explorer, not one of my custom ones of my form.

View 8 Replies

Blocking In A Service?

May 25, 2012

The subject sucks, but the problem is straightforward. I have an existing WCF service. There are a small series of functions, currently. One or two of the functions will need to be performed with a bit of security, for which I need a username and password. The username and password will be checked on the server side against a webservice running on localhost. One alternative is to not use the localhost webservice for the validation, but then I wouldn't have a question, so ignore that.

The way the webservice will work, I was thinking that I would use an invisible web browser, navigate to the REST-style URL, and wait for the response. It's the bit about waiting for the response that is causing me trouble. Normally, I'd wait for the document comleted event raised by the browser control, but since this is initiated by the call of a WCF service function, that won't really work. The WCF function call can't 'wait' for anything, nor will it receive the event. Once the WCF function reaches the End Function statement, it is over and done with, and returns. The response from the webservice won't have arrived by then, so that won't work. There are two typical solutions to this, one of which is horrible to the point of being unworkable.

1) A busy wait, or spin wait, where the WCF function goes into a tight loop waiting for the browser event to be raised. This is never a good idea, and is particularly terrible in this case, because the WCF service is running on a web server, so the negative impacts of a busy wait are FAR worse than normal.

2) Use something like a Mutex in the WCF function such that the function launches a thread, the thread immediately grabs the Mutex, then begins the navigation. The WCF function waits on the Mutex, which would mean blocking without spinning, and the document completed event pulses the Mutex to release the WCF function so that it can return the proper response. This seems technically improbable, as it stands.

The problem is only a slight variation on a very typical problem, yet it presents some interesting problems. Windows is event driven, but a WCF service function is not. A callback across a WCF (at least across this one), isn't an option, events aren't an option, so it all comes down to the function starting a process, then blocking without spinning, until the process comes up with an answer.

View 11 Replies

C# - Blocking A Thread In .Net?

Aug 13, 2010

I have a class that has purely static Methods and properties. I am calling an async method on the class "Load" that asks a web service for a chunk of data, which then fires an event that executes the return method, "LoadCompleted". I have no idea how long the call is going to take (the difference between calling the "Load" method, then the "LoadCompleted" getting called).

I would like to block the application from proceeding any further until the callback method has been raised (as the app will try and get stuff from this class, which isn't populated until the "LoadComplete" method sets the data).

View 3 Replies

Blocking An Ip From Connecting To Computer?

Sep 20, 2009

I am trying to make an app in VB.NET that pings ip's on a specfic port that are connected to my computer and if it is greater then 500 the person would be blocked from connecting to my computer. How can I do this in VB.NET?

View 1 Replies

Blocking Web Sites In Browser?

Oct 10, 2009

I am creating a security program. One of its features is that it blocks inappropriate web sites. I might need help determining which sites are bad and which ones are good. If I could 'read' every work that is displayed in the browser then I could tell, but that may come later.

So, I'm looking for some kind of hook that will allow me to cancel the site if needed. It should be able to still be hooked in Safe Mode, as well... I'm sure that this is going to be an easy one!

View 7 Replies

Blocking Websites With Browser

Sep 9, 2010

I wish to block websites in a browser, where the blocked websites are stored in my.settings.blockedwebs (which is a collections. specialized. stringcollection). I let the user input the blocked website into a textbox in form1, and the add website to the stringcollection button has the following code:[code]

View 15 Replies

IDE :: Make Firewall Blocking?

Jul 27, 2009

I am unable to get on to internet explorer or IM on my laptop . I am using Windows XP.Each time I log-in it says my firewall is blocking.

View 4 Replies

Non-blocking Task.wait In .NET 4?

Apr 30, 2012

I'm trying to wait for a Task result in .NET 4, much like you can by using the await keyword in .NET 4.5. I just can't figure out how to do it though...My code (to prove that I'm atleast trying):

Private Function GetXDocumentFromWebLocationAsync(ByVal request As WebRequest) As XDocument
Dim queryTask As Task(Of WebResponse)
queryTask = task(Of WebResponse).Factory.FromAsync(AddressOf request.BeginGetResponse, AddressOf request.EndGetResponse, Nothing, Nothing)

[code]....

As you would expect, the GetResponse calls are executed on a different thread, but the function has to wait for the result before it can return. Unfortunately this blocks my main thread until the task has completed and I don't have the slightest clue on how to make it wait without blocking. I don't want to use the Async CTP either because that's just running away from the problem.

View 1 Replies

.net - Synchronous Wait Without Blocking The UI-Thread

May 24, 2011

Is there a synchronous wait function that won't tie up the UI-thread in .NET WPF? Something like:

Sub OnClick(sender As Object, e As MouseEventArgs) Handles button1.Click
Wait(2000)
'Ui still processes other events here
MessageBox.Show("Is has been 2 seconds since you clicked the button!")
End Sub

View 1 Replies

Avoid Assembly.LoadFrom Blocking?

Jul 31, 2011

I create a .net dll on the fly with codedom then I load it with Assembly.LoadFrom like this:

Private Sub Test()
Dim ASM As Assembly = Assembly.LoadFrom("test.dll")
'Do some stuff with the loaded assembly...

[code]....

View 1 Replies

Blocking A Thread To Wait For Callback

Jan 19, 2009

I have been reading the async design patterns on MSDN and the general idea makes sense to me but in practice it is proving to be more difficult. I am working on a project utilizing VMWARE VIX.

HTML Code: [url]. Each function such as connecting to a host server, retrieving properties, etc. can be executed in two different ways.

Connecting to a host using a blocking Wait:

Code:
Dim m_lib As New VixLib
Dim m_hostJob As VixCOM.IJob

[CODE]...

Code:
Dim m_lib As New VixLib
Dim m_hostJob As VixCOM.IJob
dim m_callback as VixCOM.ICallback

[CODE]...

The problem with the VIX SDK is that sometimes the functions never return, hanging the application. dblock.

HTML Code:[URL] came up with a library that specifies a timeout value. When the timeout runs out the method aborts and returns regardless whether it finished or not.

The callback method is an active wait where the code continues to execute. What I want to implement is a blocking wait with a timeout. The ICallback interface has one sub OnVixEvent(IJob,Integer,IVixHandle). This method is fired at least twice, first when some progress is posted and second when it is complete. The first call to this method can be one second after registering the callback or 30 seconds, so I can not rely on this method to block the main thread. how to create some kind of async result class that would block the main thread from executing until either a timer runs out or the OnVixEvent method returns an Operation Complete signal that also implements ICallback.

View 10 Replies

Blocking List Of Process With Timer?

Apr 11, 2012

I am trying to block a list of processes from Txt file/ Listbox System.Diagnostic.Process using Timer. Here's the timer codes

[Code]...

I can block processes from the list using SelectedItem, but it doesn't block all the process in the list.Using while loop causes a deadlock error here. I'm now using aBlock.ReadLine to read from txt file and block the available process. However it is only able to block the first process. Need some guidance to get this code to block all the processes in the list.

View 5 Replies

C# - IO Operation Is Blocking UI And Background Thread

Jun 29, 2011

I am a novice in Threads, but I want to know how to order thread execution in my scenario, and is the following :

UI Thread : Windows Form Background
Thread : Kind of print daemon
implemented with recursive methods
IO Operation : a StreamWriter that do
the job of File.AppendText()

When I execute my main app.exe, sometimes it launches the Windows Forms and the execution process in the task manager (app.exe), in some opportunities its just launches the execution process in background. How can I determine the behavior of launching UI, I have to establish a priority or somewhat else? Code: I'm using framework 2.0 and any answers could be writted in C# or Vb.Net.

View 1 Replies

Programmatically Webpage Blocking / Filtering

May 24, 2009

how to or have a tutorial about programaticly blocking a webpage from webbrowsers? or is this not possible because it would need to be done on a router level?

View 2 Replies

Room Availability Calendar Blocking

May 26, 2011

I am developing a hotel software product, and one of the features required is to be able to display the room numbers in the hotel, and then the status of them for each day of the month.

I am trying to create something similar to a DataGridView control where at the top the column names are the dates of the month, and to the left is the room numbers as rows. Please see the below screenshot of the function I wish to have. However I do not know what control or function they use to create this grid below (it is from an existing product). I need to not just be able to join multiple cells together when it is the same person in the room for multiple days, but also allow drag and drop ability.

Currently I have a DataGridView control and am able to simulate the below screenshot, however with a datagridview control I am unable to join cells across multiple columns nor allow drag and drop ability between rows.

View 6 Replies

VS 2008 Blocking Internet Connection By IP

Jun 26, 2009

I have an app that gets all the network computers on a local network. Is there any way to block the connection of a computer by the IP/host name? I want to manage my wireless connection at home so that no one can steal my signal.I would use this app on the computer connected to the wireless router.Anyhow, is this possible? Isn't it? Many online games ban the players by IP, so I thought it could be done.

View 4 Replies

VS 2008 Firewall Blocking Emails

Jun 11, 2010

Me and my friend both wrote an app to send emails, same code. When I run my app, I can let it send an email. When I run my friends app, the firewall blocks the outgoing emails. Is there any way to let the emails send from my friends app, by changing code or so? I don't want to add it to the whitelist of the firewall.

View 5 Replies

VS 2010 - Windows Key Blocking At Runtime

Jan 16, 2011

I am trying to create an application that can block Windows keys at runtime in VB .net. Basically, if 'Disable Left Win Key' check box is checked, then the application will disable the left windows key and the same for the right one. I also want to be able to show a message box depending on whether 'Show Message Box' is checked when either win key is blocked.

View 2 Replies

Differences Between VB Functions And Convert.To* Functions?

Feb 19, 2009

While converting types, I have found myself using both VB functions and BCL Convert.To* methods.
E.g.)

Cstr() vs. Convert.ToString()
CInt() vs. Convert.ToInt32()
CDbl() vs. Convert.ToInt64()
etc...

Are there any subtle differences that should be noted?

View 1 Replies

[2005] MembershipUser Functions - See Exactly What The Functions Are Doing?

Mar 4, 2009

Is there a way to see exactly what the functions are doing. What i mean is there a way to see the class? I know what it does, i just want to know the code.
For example the function: Membership.FindUsersByName()

View 1 Replies

.net - Loading GIF Freezing Sometimes?

Feb 25, 2009

I'm trying to use a loading overlay on top of a Windows form that adds a 50% opaque layer on top of a windows form with a loading GIF, while it does what it needs to do in a background thread. The overlay is a windows form that I'm drawing in the onPaint event.

The loading overlay works fine on multiple different form loads, but fails to work properly when summoned to ensure patience during a 30 second upload process (That Prints a Word Document to PDF, then uploads that PDF to a SQL Server). This upload collects some data from the form, puts it into an Object, then operates entirely on a background thread. The loading overlay will appear, show the first frame loading GIF, then just freeze. The onPaint is getting fired and the image frame is being updated, but it isn't visible

Constructor sets the form to be UserPainted:

Sub New()
InitializeComponent()
SetStyle(ControlStyles.UserPaint Or ControlStyles.Opaque, True)
End Sub

[Code].....

View 2 Replies

FileSystemWatcher Freezing GUI?

May 25, 2010

I have a FileSystemWatcher monitoring a folder, and when many files are cut and pasted into the folder, the GUI freezes, as the 'Changed' event is fired over and over. Any way to deal with this?

View 1 Replies

My Program Keeps Freezing

May 20, 2011

My program keeps freezing. Here is my [code]...

View 10 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved