50,230 Members
3 added today
250,666 Resources
26 added today

All Devdex   All XMLdex   Current Category
XMLdex > Forums & Newsgroups > Newsgroups > microsoft.public.xml Add this category to My Favorites

View Message Thread  (35 replies)

Results 1 - 10 of 36 Next Page »

ActiveX EXE and a little more Add this thread to My Favorites
From: Bee
Date Posted: 6/1/2010 6:59:00 PM

The little more first. How/where do I access the newsgroup
comp.lang.basic.visual.misc other than through a newsreader? Is there a
Google access?

ActiveX EXE.
I have written an ActiveX EXE called AxUSB. The entry is through the class
named Entry.
I have successfully connected to it from my main app but now I need to
figure out how to do what I really need with it.
I have Subs and Functions access that work correctly.

I need to access AxUSB from several forms and AxUSB does generate Events.
If I use this following method it simplifies my development process but I do
not know how to work with events. Can it be done? How?
AxUSB is an object.
The event is named DataEvent
Const csAxUSB As String = "AxUSB.Entry"
    Set g_AxUSB = GetObject(cEmptyString, csAxUSB)
How do I set up for events using this?

If I do the following way, the development process keeps needing resetting
the Reference.

    Set g_AxUSB = New AxUSB.Entry

The only way I think I understand how to make it all play the way I
ultimately need is as follows.
I have coded enough to make the simple non-event case work fine for both
methods of instantiation.
Using the second method (not preferred).

Instantiate in the main form with
Private WithEvents AxUSB As AxUSB.Entry

Then the second form must call into the main form to get access to the
interface Subs and Functions. Or can I somehow do all that access in a .bas
that is common to all forms? Or do I write a class that raises an event that
nany form can get?
OK, I am trying to interface hardware and want to make the data come and go
as quickly as possible so the fewer things I have to go through the better.
I guess the long pole is the AxUSB interface due to the way data is moved.
Currently, I have all the time critical suff coded in the AxUSB and am seeing
it talk very quickly to the hardware.

Just needs some of your thoughts so maybe something will gel with me and I
can proceed. Never done this before and I know I am coming in through the
back door, but I am learning. Yeah, retired and trying to keep learning.
Sorry, I am a little slow.

Is this the only way or can it be done more better?

ActiveX EXE and a little more
From: Bee
Date Posted: 6/1/2010 7:00:00 PM

The little more first. How/where do I access the newsgroup
comp.lang.basic.visual.misc other than through a newsreader? Is there a
Google access?

ActiveX EXE.
I have written an ActiveX EXE called AxUSB. The entry is through the class
named Entry.
I have successfully connected to it from my main app but now I need to
figure out how to do what I really need with it.
I have Subs and Functions access that work correctly.

I need to access AxUSB from several forms and AxUSB does generate Events.
If I use this following method it simplifies my development process but I do
not know how to work with events. Can it be done? How?
AxUSB is an object.
The event is named DataEvent
Const csAxUSB As String = "AxUSB.Entry"
    Set g_AxUSB = GetObject(cEmptyString, csAxUSB)
How do I set up for events using this?

If I do the following way, the development process keeps needing resetting
the Reference.

    Set g_AxUSB = New AxUSB.Entry

The only way I think I understand how to make it all play the way I
ultimately need is as follows.
I have coded enough to make the simple non-event case work fine for both
methods of instantiation.
Using the second method (not preferred).

Instantiate in the main form with
Private WithEvents AxUSB As AxUSB.Entry

Then the second form must call into the main form to get access to the
interface Subs and Functions. Or can I somehow do all that access in a .bas
that is common to all forms? Or do I write a class that raises an event that
nany form can get?
OK, I am trying to interface hardware and want to make the data come and go
as quickly as possible so the fewer things I have to go through the better.
I guess the long pole is the AxUSB interface due to the way data is moved.
Currently, I have all the time critical suff coded in the AxUSB and am seeing
it talk very quickly to the hardware.

Just needs some of your thoughts so maybe something will gel with me and I
can proceed. Never done this before and I know I am coming in through the
back door, but I am learning. Yeah, retired and trying to keep learning.
Sorry, I am a little slow.

Is this the only way or can it be done more better?

ActiveX EXE and a little more
From: Bee
Date Posted: 6/1/2010 7:01:00 PM

The little more first. How/where do I access the newsgroup
comp.lang.basic.visual.misc other than through a newsreader? Is there a
Google access?

ActiveX EXE.
I have written an ActiveX EXE called AxUSB. The entry is through the class
named Entry.
I have successfully connected to it from my main app but now I need to
figure out how to do what I really need with it.
I have Subs and Functions access that work correctly.

I need to access AxUSB from several forms and AxUSB does generate Events.
If I use this following method it simplifies my development process but I do
not know how to work with events. Can it be done? How?
AxUSB is an object.
The event is named DataEvent
Const csAxUSB As String = "AxUSB.Entry"
    Set g_AxUSB = GetObject(cEmptyString, csAxUSB)
How do I set up for events using this?

If I do the following way, the development process keeps needing resetting
the Reference.

    Set g_AxUSB = New AxUSB.Entry

The only way I think I understand how to make it all play the way I
ultimately need is as follows.
I have coded enough to make the simple non-event case work fine for both
methods of instantiation.
Using the second method (not preferred).

Instantiate in the main form with
Private WithEvents AxUSB As AxUSB.Entry

Then the second form must call into the main form to get access to the
interface Subs and Functions. Or can I somehow do all that access in a .bas
that is common to all forms? Or do I write a class that raises an event that
nany form can get?
OK, I am trying to interface hardware and want to make the data come and go
as quickly as possible so the fewer things I have to go through the better.
I guess the long pole is the AxUSB interface due to the way data is moved.
Currently, I have all the time critical suff coded in the AxUSB and am seeing
it talk very quickly to the hardware.

Just needs some of your thoughts so maybe something will gel with me and I
can proceed. Never done this before and I know I am coming in through the
back door, but I am learning. Yeah, retired and trying to keep learning.
Sorry, I am a little slow.

Is this the only way or can it be done more better?

ActiveX EXE and a little more
From: Bee
Date Posted: 6/1/2010 7:03:00 PM

The little more first. How/where do I access the newsgroup
comp.lang.basic.visual.misc other than through a newsreader? Is there a
Google access?

ActiveX EXE.
I have written an ActiveX EXE called AxUSB. The entry is through the class
named Entry.
I have successfully connected to it from my main app but now I need to
figure out how to do what I really need with it.
I have Subs and Functions access that work correctly.

I need to access AxUSB from several forms and AxUSB does generate Events.
If I use this following method it simplifies my development process but I do
not know how to work with events. Can it be done? How?
AxUSB is an object.
The event is named DataEvent
Const csAxUSB As String = "AxUSB.Entry"
    Set g_AxUSB = GetObject(cEmptyString, csAxUSB)
How do I set up for events using this?

If I do the following way, the development process keeps needing resetting
the Reference.

    Set g_AxUSB = New AxUSB.Entry

The only way I think I understand how to make it all play the way I
ultimately need is as follows.
I have coded enough to make the simple non-event case work fine for both
methods of instantiation.
Using the second method (not preferred).

Instantiate in the main form with
Private WithEvents AxUSB As AxUSB.Entry

Then the second form must call into the main form to get access to the
interface Subs and Functions. Or can I somehow do all that access in a .bas
that is common to all forms? Or do I write a class that raises an event that
nany form can get?
OK, I am trying to interface hardware and want to make the data come and go
as quickly as possible so the fewer things I have to go through the better.
I guess the long pole is the AxUSB interface due to the way data is moved.
Currently, I have all the time critical suff coded in the AxUSB and am seeing
it talk very quickly to the hardware.

Just needs some of your thoughts so maybe something will gel with me and I
can proceed. Never done this before and I know I am coming in through the
back door, but I am learning. Yeah, retired and trying to keep learning.
Sorry, I am a little slow.

Is this the only way or can it be done more better?

Re: ActiveX EXE and a little more
From: dpb
Date Posted: 6/1/2010 7:54:00 PM

Bee wrote:
> The little more first. How/where do I access the newsgroup
> comp.lang.basic.visual.misc other than through a newsreader? Is there a
> Google access?

Well, yes, there's the google groups webreader but why in the world
anybody puts up w/ it for reading/posting is beyond ken...

It's useful for topic searches and historical archives but outside that
it sucks big time.

....

Sorry, I know very little ActiveX so I'll pass on that to somebody who
does... :)

--

Re: ActiveX EXE and a little more
From: dpb
Date Posted: 6/1/2010 7:55:00 PM

Bee wrote:
> The little more first. How/where do I access the newsgroup
> comp.lang.basic.visual.misc other than through a newsreader? Is there a
> Google access?

Well, yes, there's the google groups webreader but why in the world
anybody puts up w/ it for reading/posting is beyond ken...

It's useful for topic searches and historical archives but outside that
it sucks big time.

....

Sorry, I know very little ActiveX so I'll pass on that to somebody who
does... :)

--

Re: ActiveX EXE and a little more
From: dpb
Date Posted: 6/1/2010 7:56:00 PM

Bee wrote:
> The little more first. How/where do I access the newsgroup
> comp.lang.basic.visual.misc other than through a newsreader? Is there a
> Google access?

Well, yes, there's the google groups webreader but why in the world
anybody puts up w/ it for reading/posting is beyond ken...

It's useful for topic searches and historical archives but outside that
it sucks big time.

....

Sorry, I know very little ActiveX so I'll pass on that to somebody who
does... :)

--

Re: ActiveX EXE and a little more
From: dpb
Date Posted: 6/1/2010 7:57:00 PM

Bee wrote:
> The little more first. How/where do I access the newsgroup
> comp.lang.basic.visual.misc other than through a newsreader? Is there a
> Google access?

Well, yes, there's the google groups webreader but why in the world
anybody puts up w/ it for reading/posting is beyond ken...

It's useful for topic searches and historical archives but outside that
it sucks big time.

....

Sorry, I know very little ActiveX so I'll pass on that to somebody who
does... :)

--

Re: ActiveX EXE and a little more
From: ralph
Date Posted: 6/1/2010 10:53:00 PM

On Tue, 1 Jun 2010 17:58:01 -0700, Bee <Bee@discussions.microsoft.com>
wrote:


>
>I need to access AxUSB from several forms and AxUSB does generate Events.
>If I use this following method it simplifies my development process but I do
>not know how to work with events. Can it be done? How?
>AxUSB is an object.
>The event is named DataEvent
>Const csAxUSB As String = "AxUSB.Entry"
>    Set g_AxUSB = GetObject(cEmptyString, csAxUSB)
>How do I set up for events using this?
>

If AxUSB is declared as an Object then you can't capture Events, ie.
you need to use early binding, late binding will not work.

This is because of the way VB manages and creates Event Sinks.
There are some Rube Goldberg methods you might employ, but it doesn't
sound like you need to go there.

>If I do the following way, the development process keeps needing resetting
>the Reference.
>

This always a problem with creating an ActiveX.

Using Project and Binary Compatibility with both your client and
server can help.

The best policy is to design and create the Interface first. If you
find you need to add major 'blocks' of functionality consider defining
additional Interfaces (objects) instead.

>
>Instantiate in the main form with
>Private WithEvents AxUSB As AxUSB.Entry
>
>Then the second form must call into the main form to get access to the
>interface Subs and Functions. Or can I somehow do all that access in a .bas
>that is common to all forms? Or do I write a class that raises an event that
>nany form can get?

Assuming your client is only going to use one instance, simply create
the object once and then create a simple constructor for each of your
forms and classes to pass the reference them.

hth
-ralph

Re: ActiveX EXE and a little more
From: ralph
Date Posted: 6/1/2010 10:54:00 PM

On Tue, 1 Jun 2010 17:58:01 -0700, Bee <Bee@discussions.microsoft.com>
wrote:


>
>I need to access AxUSB from several forms and AxUSB does generate Events.
>If I use this following method it simplifies my development process but I do
>not know how to work with events. Can it be done? How?
>AxUSB is an object.
>The event is named DataEvent
>Const csAxUSB As String = "AxUSB.Entry"
>    Set g_AxUSB = GetObject(cEmptyString, csAxUSB)
>How do I set up for events using this?
>

If AxUSB is declared as an Object then you can't capture Events, ie.
you need to use early binding, late binding will not work.

This is because of the way VB manages and creates Event Sinks.
There are some Rube Goldberg methods you might employ, but it doesn't
sound like you need to go there.

>If I do the following way, the development process keeps needing resetting
>the Reference.
>

This always a problem with creating an ActiveX.

Using Project and Binary Compatibility with both your client and
server can help.

The best policy is to design and create the Interface first. If you
find you need to add major 'blocks' of functionality consider defining
additional Interfaces (objects) instead.

>
>Instantiate in the main form with
>Private WithEvents AxUSB As AxUSB.Entry
>
>Then the second form must call into the main form to get access to the
>interface Subs and Functions. Or can I somehow do all that access in a .bas
>that is common to all forms? Or do I write a class that raises an event that
>nany form can get?

Assuming your client is only going to use one instance, simply create
the object once and then create a simple constructor for each of your
forms and classes to pass the reference them.

hth
-ralph

Results 1 - 10 of 36 Next Page »

 

Would you like to track this thread?

By adding this News Thread to your Favorites Area you can refer to it later with just a click of the mouse. Also you can optionally be notified instantly whenever there are any replies posted to this Thread. To add this Thread to your Favorites Area just click on the red arrow next to the subject of the thread above Add this thread to My Favorites.



Credit Card Payment Control
Supports over 25 companies
Managed ASP.NET Solution
Direct Processor Support

ASP ArticlesThis category has been added to your weekly newsletter
ASP Web Sites
ADSI & WSH BooksThis category has been added to your weekly newsletter
FREE ComponentsThis category has been added to your weekly newsletter
ASP EventsThis category has been added to your weekly newsletter
ASP HeadlinesThis category has been added to your weekly newsletter

CSharp ArticlesThis category has been added to your weekly newsletter
C# Web SitesThis category has been added to your weekly newsletter

SQL ArticlesThis category has been added to your weekly newsletter
SQL Events
SQL HeadlinesThis category has been added to your weekly newsletter
SQL Jobs

Jobs in CaliforniaThis category has been added to your weekly newsletter

XML ArticlesThis category has been added to your weekly newsletter
XML BooksThis category has been added to your weekly newsletter
XML Web Sites
XML Tutorials

free asp host

"Alex Homer"This search has been added to your weekly newsletter

Edit My Favorites Edit Profile & Favorites

 

 

 

 

 




Developersdex Home | ASP | C# | SQL | VB | XML | Gurus
Add Your Link | Add Your Code | FAQ | Advertise | Link To Us | Contact Us |
Copyright © 2010 Developersdex™. All rights reserved.