User Profile

Collapse

Profile Sidebar

Collapse
zhang
zhang
Last Activity: Oct 14 '07, 03:01 AM
Joined: Sep 23 '06
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • zhang
    started a topic vb databse record to excel cell

    vb databse record to excel cell

    I had a problem when I try to send some data from database to Excel. The error information is : Error 1004 application-defined or object defined.

    this error come from following code:

    mysheet.cells(1 1, 1) = temp_set.Fields (12)

    If the data string length (temp_set.Field s(12)) is not so long (around less then 800). it works fine. Only when the string length is long (>1000), the error will come.
    ...
    See more | Go to post

  • zhang
    started a topic Vb Ole Excel

    Vb Ole Excel

    I have a project to embed Excel in VB application using OLE. However, when running this application, I found that I can't put Formula Bar on EXCEL. Is there any way to open EXCEL on Emdeded OLE as usual.

    By the way, the interface(VB Form and EXCEL object) using OLE looks ugly. Are there any better ways in VB to control EXCEL and communicate from VB to EXCEL?

    Any suggestion is welcome. Thank you inadvance.
    ...
    See more | Go to post

  • zhang
    replied to vb progress bar
    Hi,Killer42

    The below is my ugly code, any help is welcomed.Thank you for your encouraging.

    Zhang


    ‘main subroutine
    Sub cmdLoad_click()
    Dim ExcelFileName as String
    Dim TableName as String
    ……..
    ‘Assign values to variables
    Timer.Enabled=t rue
    Timer.Interval= 300
    Select Case Me.tabAdd.Selec tedItem.Index

    Case 1:
    ‘do...
    See more | Go to post

    Leave a comment:


  • zhang
    replied to vb progress bar
    Killer42,

    Yes, as you analysized what I am doing is to open Excel file then sned a bunch of data to this file. It takes some time and i think I can't gain control of procedure at this moment until the job done. I try to put doEvents and looks it doesn't work either.
    I remembered Java can create multi-processes at same time.
    Does Vb has features of multi-threads like Java? Or do you have any other suggestion for this...
    See more | Go to post

    Leave a comment:


  • zhang
    replied to vb progress bar
    Thanks Bruce,

    Actually my progress bar works if my code is a simple calculation(suc h as long for loop), But, if I try to open external database and transfer data, the progress bar stops and will restore until the job done.

    By the way, i checked the "techrepubi lc" and have a question; what's meaning of "Put the code you want executed in the Timer event procedure". need i put my code inside of timer...
    See more | Go to post

    Leave a comment:


  • zhang
    started a topic vb progress bar

    vb progress bar

    Hi, every one

    I have a vb application to open/close and send data from database to Excel file. It takes some time, so I want to show user the progress bar to confirm the job is going. But, I failed and please give me some suggestions. Code is blow:

    sub do something()

    timer.enable=tr ue

    '
    here my code for tranferring data between Excel and database and so on
    ' finish the job...
    See more | Go to post

  • CaptainD,

    I tested as you suggestion. it only work as you press arrow key, any letter key still work as usual. Following is my code:

    Private Sub dbgEquip_KeyDow n(KeyCode As Integer, Shift As Integer)
    Dim colNo As Integer
    colNo = Me.dbgEquip.Col
    If colNo = 0 Then
    KeyCode = 0
    End If

    End Sub

    Anyway, thank you lots

    Zhang...
    See more | Go to post

    Leave a comment:


  • need some fields not editable in data grid VB 6.0

    Hi,

    I try to protect some fields from editing by user after the records of table showing in datagrid using VB 6.0. How can I do?

    Please help

    Zhang
    See more | Go to post
No activity results to display
Show More
Working...