Jx_Man 987 Nearly a Senior Poster Featured Poster

hell

Jx_Man 987 Nearly a Senior Poster Featured Poster

quack
care
ace

against

Jx_Man 987 Nearly a Senior Poster Featured Poster

-8:)1

Jx_Man 987 Nearly a Senior Poster Featured Poster

4484

Jx_Man 987 Nearly a Senior Poster Featured Poster

txtStartUp is path of startup folder
YourExeNameOnStartUpFolder.exe is your exe file name when it copied into startup folder.
put this following code into your current event :

FileCopy App.EXEName & ".exe", txtStartupPath & "\YourExeNameOnStartUpFolder.exe"
msgbox "Copying Success"

Hope this helps...

Estella commented: nice one +1
november_pooh commented: always help with great code :) +1
ITKnight commented: Good +1
Jx_Man 987 Nearly a Senior Poster Featured Poster

you're welcome ;)

Jx_Man 987 Nearly a Senior Poster Featured Poster

see this following code :

Dim mShell
Set mShell = CreateObject("WScript.Shell")
txtPath  = mShell.SpecialFolders("Startup")

Hope this helps..

november_pooh commented: thank you very much +1
Jx_Man 987 Nearly a Senior Poster Featured Poster

on below of last post you can see a link "mark as solved", click on it to make this thread solved.

Jx_Man 987 Nearly a Senior Poster Featured Poster

why you must get startup path??what you want to do?

Jx_Man 987 Nearly a Senior Poster Featured Poster

you're welcome knight.
happy coding friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

well great, maybe u can teach others with your program. happy coding friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

this following code to read name and serial number of HD :

Private Type DRIVEINFO
    HDDModel As String
    HDDIType As String
    HDDSerialNum As String
End Type
   
Dim info As DRIVEINFO
Public Function HDDSerialNumber()
Dim objs As Object
Dim obj As Object
Dim WMI As Object
    
    Set WMI = GetObject("WinMgmts:")
    Set objs = WMI.InstancesOf("Win32_DiskDrive")
    For Each obj In objs
        info.HDDModel = obj.Model
        info.HDDIType = obj.InterfaceType
    Next obj
    
    Set objs = WMI.InstancesOf("Win32_PhysicalMedia")
    For Each obj In objs
        info.HDDSerialNum = obj.SerialNumber
    Next obj
    Text1.Text = info.HDDModel
    Text2.Text = info.HDDIType
    Text3.Text = info.HDDSerialNum
End Function

Private Sub Form_Load()
HDDSerialNumber
End Sub
Jx_Man 987 Nearly a Senior Poster Featured Poster

Hi Pieter...Welcome to Daniweb Friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

Hi Mark...welcome to Daniweb friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

what database that u using on?sqlserver or access?

Jx_Man 987 Nearly a Senior Poster Featured Poster

yes. just change the directory of flash file (.swf).

Jx_Man 987 Nearly a Senior Poster Featured Poster

Hi Joseph...Welcome to Daniweb Friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

Hi Welcome to Daniweb Friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

Hi...Welcome to Daniweb Friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

so u already added shockwaveflash on form. next move is write a code. u can see on this thread for second post (#2), there are code for play flash file (.swf)

Jx_Man 987 Nearly a Senior Poster Featured Poster

add timer, set interval = 100 on interval properties.

Private Sub tmrCek_Timer()
On Error Resume Next
    Call List_Process
End Sub

hope this helps..

Vega_Knight commented: great :) +1
Neji commented: so beatifull +1
november_pooh commented: ??help to learn +1
Jx_Man 987 Nearly a Senior Poster Featured Poster

you're welcome

Jx_Man 987 Nearly a Senior Poster Featured Poster

there are none error, your code its fine. what the error that you found in it?? the bold code its right.

Jx_Man 987 Nearly a Senior Poster Featured Poster

use this follwing code :
needed two listbox named list1 and list2

Const TH32CS_SNAPHEAPLIST = &H1
Const TH32CS_SNAPPROCESS = &H2
Const TH32CS_SNAPTHREAD = &H4
Const TH32CS_SNAPMODULE = &H8
Const TH32CS_SNAPALL = (TH32CS_SNAPHEAPLIST Or TH32CS_SNAPPROCESS Or TH32CS_SNAPTHREAD Or TH32CS_SNAPMODULE)
Const TH32CS_INHERIT = &H80000000
Const MAX_PATH As Integer = 260
Private Type PROCESSENTRY32
    dwSize As Long
    cntUsage As Long
    th32ProcessID As Long
    th32DefaultHeapID As Long
    th32ModuleID As Long
    cntThreads As Long
    th32ParentProcessID As Long
    pcPriClassBase As Long
    dwFlags As Long
    szExeFile As String * MAX_PATH
End Type
Private Declare Function CreateToolhelp32Snapshot Lib "kernel32" (ByVal lFlags As Long, ByVal lProcessID As Long) As Long
Private Declare Function Process32First Lib "kernel32" (ByVal hSnapShot As Long, uProcess As PROCESSENTRY32) As Long
Private Declare Function Process32Next Lib "kernel32" (ByVal hSnapShot As Long, uProcess As PROCESSENTRY32) As Long
Private Declare Function OpenProcess Lib "kernel32.dll" (ByVal dwDesiredAccess As Long, ByVal bInheritHandle As Long, ByVal dwProcessId As Long) As Long
Private Declare Function TerminateProcess Lib "kernel32.dll" (ByVal hProcess As Long, ByVal uExitCode As Long) As Long
Private Declare Function CloseHandle Lib "kernel32.dll" (ByVal hHandle As Long) As Long
Private Const PROCESS_ALL_ACCESS = &H1F0FFF
'Enum the path
Private Const PROCESS_QUERY_INFORMATION As Long = &H400
Private Const PROCESS_VM_READ = &H10
Private Declare Function EnumProcessModules Lib "psapi.dll" (ByVal hProcess As Long, ByRef lphModule As Long, ByVal cb As Long, ByRef cbNeeded As Long) As Long
Private Declare Function GetModuleFileNameExA Lib "psapi.dll" (ByVal hProcess As Long, ByVal hModule As Long, ByVal ModuleName As String, ByVal nSize As Long) As Long


Private …
ITKnight commented: thanks :) +1
Estella commented: wow, Great Code :D +1
Sawamura commented: Great Code :) +1
Jx_Man 987 Nearly a Senior Poster Featured Poster

use this following code :

Private Const MAX_COMPUTERNAME_LENGTH As Long = 31
Private Declare Function GetComputerName Lib "kernel32" Alias "GetComputerNameA" (ByVal lpBuffer As String, nSize As Long) As Long

Private Sub GetCompName()
Dim dwLen As Long
    Dim strString As String
    'Create a buffer
    dwLen = MAX_COMPUTERNAME_LENGTH + 1
    strString = String(dwLen, "X")
    'Get the computer name
    GetComputerName strString, dwLen
    'get only the actual data
    strString = Left(strString, dwLen)
    'Show the computer name
    MsgBox "WELCOME " & strString
   
End Sub

Private Sub Form_Load()
GetCompName
End Sub
Naruse commented: this is very Great Code. Works like charm :). thanks buddy +1
Neji commented: help me too +1
Jx_Man 987 Nearly a Senior Poster Featured Poster

Hi Aled Welcome to Daniweb Friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

Hi Zanziff Welcome to Daniweb Friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

Hi...Welcome to Daniweb Friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

you just to handle keychar, but you must know the ascii of letters. this following code will not allowed you to input other character except letters or strings. so u cannot input number or other special character.
try this following code :

Private Sub textDate_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles textDate.KeyPress
        If (Microsoft.VisualBasic.Asc(e.KeyChar) < 65) _
             Or (Microsoft.VisualBasic.Asc(e.KeyChar) > 90) _
             And (Microsoft.VisualBasic.Asc(e.KeyChar) < 97) _
             Or (Microsoft.VisualBasic.Asc(e.KeyChar) > 122) Then
            'space accepted
            If (Microsoft.VisualBasic.Asc(e.KeyChar) <> 32) Then
                e.Handled = True
            End If
        End If
        If (Microsoft.VisualBasic.Asc(e.KeyChar) = 8) Then
            
            e.Handled = False
        End If
    End Sub
Jx_Man 987 Nearly a Senior Poster Featured Poster

you're welcome friend :)
Happy coding...

Jx_Man 987 Nearly a Senior Poster Featured Poster

C#.net step by step. or try to make calculator.

Jx_Man 987 Nearly a Senior Poster Featured Poster
If IsDate(textDate.Text) = True Then
            MsgBox("correct date")
        Else
            MsgBox("input correct date")
        End If
ITKnight commented: usefull +1
dnk commented: great +1
Jx_Man 987 Nearly a Senior Poster Featured Poster

Hi neubi...Welcome to Daniweb Friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

HI Mahdi...Welcome to Daniweb Friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

what data format??specify more the problem friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

why you don't remove all item on left list, so none items well of in left list. all items has been moved to right list.
it make you don't have to prompt an error message when user click the same button.

Jx_Man 987 Nearly a Senior Poster Featured Poster

just post the code that you write..don't post the generated code by vb.net and please use code tags.
so what the effort of your program?

Jx_Man 987 Nearly a Senior Poster Featured Poster

Hi...Welcome to Daniweb friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

HiG.O.D fada...Welcome to Daniweb Friend :)
Hi Bala prasad... Welcome to Daniweb Friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

Hi Sam...Welcome to Daniweb Friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

hi thando..welcome to daniweb friend :).
what version of vb that u using to play flash??
vb 6 or vb.net cause derice use .net.
if u using vb.net, u can download the file for flash player using .net on my post above # 4, named "Flash Player.Zip"
what the problem that u facing now?error or what?
Post your code, so we can help u.

Jx_Man 987 Nearly a Senior Poster Featured Poster

Hi bc...Welcome to Daniweb friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

Hi Alex...Welcome to Daniweb Friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

you're welcome sainiricha.
don't forget to mark this thread solved.
happy coding friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

make calculator maybe a simple program to you. i do this project when i learned vb at first time.

Jx_Man 987 Nearly a Senior Poster Featured Poster

you're welcome.
please mark this thread solved.
happy coding friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

Hi twojays...Welcome to Daniweb Friend :)

Jx_Man 987 Nearly a Senior Poster Featured Poster

show your code and what the effort of that.

Jx_Man 987 Nearly a Senior Poster Featured Poster
SELECT * FROM TableName WHERE ColumnName like '%" & textBox1.Text & "%'
Naruse commented: got it +1
Jx_Man 987 Nearly a Senior Poster Featured Poster
select a.id, a.colname, b.colname from Table1 a join Table2 a on (a.id=b.id) where a.id = '1' order by a.id asc
Naruse commented: thanks +1