Rekans, saya mo tanya neh, saya kan buat file excel
dari vb, trs saya mo hapus via vb jg, tp kenapa ga bs
y, katanya file is in use, pdhl kan ga saya buka, tp
wkt saya restart, emang ada seh betul excel yg
kebuka,cuma kl dr task manager ko ga keliatan seh???
salah di script saya ga seh, ini neh scriptnya :
Set objapp = New Excel.Application

objapp.Visible = False  
    Set objbook = objapp.Workbooks.Add
    Set objsheet1 = objapp.Worksheets.Add

    objsheet1.Name = Left(Trim("RelotRecall"), 30)

    objsheet1.Cells(1, 1).Value =
Trim(rsAdjustment(0).Name)
    objsheet1.Cells(1, 2).Value =
Trim(rsAdjustment(1).Name)
    objsheet1.Cells(1, 3).Value =
Trim(rsAdjustment(2).Name)
    objsheet1.Cells(1, 4).Value =
Trim(rsAdjustment(3).Name)
    objsheet1.Cells(1, 5).Value =
Trim(rsAdjustment(4).Name)
    objsheet1.Cells(1, 6).Value = Trim(rsAdjustment   

    objsheet1.Columns("A:AY").EntireColumn.AutoFit
 
    objsheet1.Range("A2").CopyFromRecordset
rsAdjustment
    objbook.SaveAs "C:\RECALL_NZMI\Adjusment.xls"
    
    Set objsheet1 = Nothing
    Set objapp = Nothing

Tolong ya rekans, kasih tau saya dimn errornya.O iy,
sblm ini dijalanin, die jalanin function hapus dulu,
gini neh..:
Dim FileOperation As SHFILEOPSTRUCT
Dim lReturn As Long
On Error GoTo DelToRecycBin_Err
  With FileOperation
     .wFunc = F0_DELETE
     .pFrom = FileName
     .fFlags = F0F_ALLOWUNDO + F0F_CREATEPROGRESSDLG
  End With
  lReturn = SHFileOperation(FileOperation)
  Exit Function
DelToRecycBin_Err:
  MsgBox Err.Number & Err.Description

Kalo saya pake ini, muncul kotak konfirmasi hapus or
tidaknya itu, saya seh mau nya ga pake konfirmasi
lg,gimana y hrsnya, biar bisa ky yg saya mau td....

Thanx..
Hasan

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 


Wahana Programmer Groups Links

<*> Untuk mengunjungi sponsor milis ini, klik link berikut:
    http://wahanaprogrammer.net

<*> Untuk menghubungi owner milis ini, kirim email ke:
    [EMAIL PROTECTED]

<*> Konsultasi pemrogramman bisa chat disini:
    Yahoo! Messenger: wahanaprogrammer
 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/Programmer-VB/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Kirim email ke