Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
R

RookieThomas

@RookieThomas
About
Posts
3
Topics
1
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • DataGrid
    R RookieThomas

    Hallo , i think this is help you. http://www.codeproject.com/csharp/webservicecache.asp Regards Thomas

    Visual Basic database

  • Filewatcher VB2005
    R RookieThomas

    Hallo thanks for answere. First the txt file not look every half an hour exectly so i want do this with the watcher. My vb is VB2005 netframework2. In this Code i look for change filter on the sms.txt file. Then i have an Frmsms its look informations about the productivity of some works. I want only refresh the label in this Form and the translated message from you is correct. If the txt changed a msgbox is popup i have test it.Thats all correct by the handle but if i do refresh or do anything outside this class (frmsms.label5.refresh) or else the error is pop up.. I look to command my code and post nearly. Thanks Thomas

    Visual Basic help question database com

  • Filewatcher VB2005
    R RookieThomas

    Hallo all, first sorry for my English. I have a problem. I build an good aplication with a form. In this i show my college some interesting details as text in an label. They only must press a button every have an hour an see the new informations. So i take this informations from an automatik create info.txt file.. I think with the filewatcher i can show it every half an hour automaticly in the lbinfo label in form1 but there come everytime this error: Its look in German sorry . Fehler beim Erstellen des Formulars. Weitere Informationen finden Sie in Exception.InnerException. Fehler: Für den aktuellen Thread muss der STA-Modus (Single Thread Apartment) festgelegt werden, bevor OLE-Aufrufe ausgeführt werden können. Stellen Sie sicher, dass die Hauptfunktion mit STAThreadAttribute gekennzeichnet ist . This is my code for working: so its easiere to understand? Imports System.IO Module Watchertest Sub Run() ' Create a new FileSystemWatcher and set its properties. Dim watcher As New FileSystemWatcher() watcher.Path = ("c:\sms\") ' Only watch text files. watcher.Filter = "sms.txt" ' Add event handlers. AddHandler watcher.Created, AddressOf OnChanged ' Begin watching. watcher.EnableRaisingEvents = True End Sub ' Define the event handlers. Sub OnChanged(ByVal source As Object, ByVal e As FileSystemEventArgs) ' Specify what is done when a file is changed, created, or deleted. MsgBox("File: " & e.FullPath & " " & e.ChangeType) FrmSms.Cursor = Cursors.WaitCursor FrmSms.TxtMis.Text = Nothing Call Mis_Sql_connect.sql_con() FrmSms.TxtMis.Visible = True FrmSms.TxtMis.Text = Trim(info) FrmSms.Cursor = Cursors.Default End Sub End Module :(( Thanks for help. Regards Thomas

    Visual Basic help question database com
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups