473,790 Members | 2,850 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

timer1.stop

cj
This program is used to send files to an ftp server at 2:00am each day.
At the very top of my program I dim a new instance of a com FTP
control. I have a processing sub which calls a login function which runs
the ftp controls login method and verifies it got logged in. The
processing sub then calls a remote directory function. The remote
directory function calls the com controls method to open the directory
for a remote directory listing and gets the listing.

The processing sub can be called from a button click or from the
timer1.tick event. Testing using the button is great. When the timer
kicks it off it logs in fine and then gives "There is no source code
available for the current location" on myftpClient.ope ndirectory which
is the com controls method to open the directory for a remote directory
listing.

This solves the problem but why? The first line in the processing sub
is Timer1.stop. I do this to keep it from trying to start processing
again while processing is running. The last line in the processing sub
is Timer1.start. If instead of doing this I use a boolean variable as a
flag saying processing is occurring I have no problems. Why would
timer1.stop cause this problem? And why would it allow the login to
work but not the opendirectory?

I expect it's something simple I'm not understanding about timer events.
Please enlighten me.
Dec 11 '06 #1
3 2057
cj
I was using VB2003. I upgraded the project to VB2005 and it works as I
first designed it. ????
cj wrote:
This program is used to send files to an ftp server at 2:00am each day.
At the very top of my program I dim a new instance of a com FTP
control. I have a processing sub which calls a login function which runs
the ftp controls login method and verifies it got logged in. The
processing sub then calls a remote directory function. The remote
directory function calls the com controls method to open the directory
for a remote directory listing and gets the listing.

The processing sub can be called from a button click or from the
timer1.tick event. Testing using the button is great. When the timer
kicks it off it logs in fine and then gives "There is no source code
available for the current location" on myftpClient.ope ndirectory which
is the com controls method to open the directory for a remote directory
listing.

This solves the problem but why? The first line in the processing sub
is Timer1.stop. I do this to keep it from trying to start processing
again while processing is running. The last line in the processing sub
is Timer1.start. If instead of doing this I use a boolean variable as a
flag saying processing is occurring I have no problems. Why would
timer1.stop cause this problem? And why would it allow the login to
work but not the opendirectory?

I expect it's something simple I'm not understanding about timer events.
Please enlighten me.
Dec 11 '06 #2
Hi cj,

Based on my understanding, the issue:
1) Only occurs in .NET 1.1
2) Only when you're calling Timer.Stop() in the beginning of Tick event
3) Occurs when calling the COM component's OpenDirectory() method

Please correct me if I've misunderstood anything.

To troubleshoot this issue, I have to ask some questions first:
1) What's the exact exception you're seeing?
2) Do you mean removing "Timer1.Sto p" in the Tick event will fix the issue?
3) Is it related to the specific com component you're using? I mean, if we
use some other com component in the Tick event, do you still see the issue?
I'm afraid without reproducible project, it's difficult to troubleshoot and
find the root cause on my side.

In the meanwhile, I'll check the implementation changes in the Timer code
from 1.1 to 2.0 to see if there's any break changes.
Sincerely,
Walter Wang (wa****@online. microsoft.com, remove 'online.')
Microsoft Online Community Support

=============== =============== =============== =====
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications. If you are using Outlook Express, please make sure you clear the
check box "Tools/Options/Read: Get 300 headers at a time" to see your reply
promptly.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.
=============== =============== =============== =====

This posting is provided "AS IS" with no warranties, and confers no rights.


Dec 12 '06 #3
cj
I understand it is hard to solve a problem unless your looking at the
code. I also found that the same program opened and compiled in VB2005
does not have the problem. Given I'm on a tight time frame and there is
no reason this can't be done in VB2005 that's what I'm going to do.

I appreciate your help but I don't have time to figure out why it will
not work in 2003. I'll just use 2005.

Thanks
Walter Wang [MSFT] wrote:
Hi cj,

Based on my understanding, the issue:
1) Only occurs in .NET 1.1
2) Only when you're calling Timer.Stop() in the beginning of Tick event
3) Occurs when calling the COM component's OpenDirectory() method

Please correct me if I've misunderstood anything.

To troubleshoot this issue, I have to ask some questions first:
1) What's the exact exception you're seeing?
2) Do you mean removing "Timer1.Sto p" in the Tick event will fix the issue?
3) Is it related to the specific com component you're using? I mean, if we
use some other com component in the Tick event, do you still see the issue?
I'm afraid without reproducible project, it's difficult to troubleshoot and
find the root cause on my side.

In the meanwhile, I'll check the implementation changes in the Timer code
from 1.1 to 2.0 to see if there's any break changes.
Sincerely,
Walter Wang (wa****@online. microsoft.com, remove 'online.')
Microsoft Online Community Support

=============== =============== =============== =====
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications. If you are using Outlook Express, please make sure you clear the
check box "Tools/Options/Read: Get 300 headers at a time" to see your reply
promptly.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.
=============== =============== =============== =====

This posting is provided "AS IS" with no warranties, and confers no rights.

Dec 12 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
5206
by: engsol | last post by:
I'm using Python to parse a bunch of s/w test files and make csv files for later report generation by MS ACCESS....(my boss loves the quick turn-around compared to C). Each log file may contain one or more 'sessions', and each session may contain one or more 'nodes'. Each session in the log has an ASCII start and stop time, as does each node. I have the basic parse part done for parameters, errors, etc., but noticed my routine for...
8
2046
by: Eric Osman | last post by:
My javascript program has reason to want to stop. For example, function A has 5 lines, the second of which calls function B, which has 5 lines, the first of which calls function C. But function C discovers that something is very wrong so it does an "alert" saying something like Sorry, couldn't make the necessary connection
5
27345
by: Paul O. Morris | last post by:
Is there a script that I can run to stop a particular SQL server service on Win2003 server? I'm looking for a similar script to restart that service as well. Thanks.
2
2120
by: Adrian MacNair | last post by:
Hi I need some help if anyone can understand my crap javascript. The problem is that after the slideshow ends (reaches the end of array) it should stop, but the timeout doesn't clear and I can see the layer flashing. I wrote a slideshow script. When you click a hypertext link it calls the function speed() and passes the variable 5000: var myvar = 0; // Starting variable at zero var myTimeout;
2
2863
by: Prasad | last post by:
Hi, I am writing a service which takes a long time to stop after the OnStop call is given by the Services Snap-in. The problem is I cannot cut down on the time that it takes to Stop. The Service snap-in gives me the error saying that the service did not respond to the Stop call in a timely fashion. So is there any method by which I can get around this problem. Thanks Prasad
16
12665
by: deko | last post by:
I have a sub routine that searches the Outlook PST for a message sent to/from a particular email address. Obviously, this can take a long time when the PST contains thousands of messages. I'd like to put a button on my Access 20003 form that will stop the sub routine when clicked. I know I can press Ctl + Break and stop the code, but is there a more graceful way to do this programmatically? Should I use SendKeys? Also, it would be...
8
3523
by: Matt Theule | last post by:
While stepping through an ASP.NET project, I found that data was being inserted into my database even though I was not stepping through the code that inserted the data. I have a single page with inline code. The page has a Datagrid, a textbox and a button. When the button is clicked, the value of the textbox is inserted into the table whose contents are displayed on the page. The problem occurs when I set a breakpoint on a line *IN*...
7
7236
by: shai | last post by:
I am working at .net 1.1, writing in c#. I have windows service with a COM object. Every unexpected time The COM object throw an error that make my service get stuck (do not respond). I can catch this error. I want to restart my windows service every time the COM object throws an error. I use System.ServiceProcess.ServiceController to stop and start my service. But there is one thing I do not understand:
0
2202
by: mattcfisher | last post by:
Hi, I have two windows services running together. One is the main program, and one is an "updater" wrapper for the main. The updater service starts and stops the main one (as in you should never start or stop main service manually, only updater). On most computers it works great, the updater's onStop() can start and stop the main service perfectly. On some computers, though, the updater hangs when it tries to stop the main service. It...
0
9666
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
9512
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
10200
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
10145
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
9986
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...
1
7530
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
5422
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
2
3707
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2909
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.