none
Help with a loop construction to send to excel cells RRS feed

  • Question

  • So, this is the question:

    i'm new on visual basic, and i need to make a loop to fill a column on excel with variables that i calculate ex:

    i have a total time (t)

    and i have a time interval that is 1/10 of the total time (dt)

    and i want that starting from C2 = first time interval until reachs the total time, but, the total time and the time interval wasn't sometimes integer values, one option is to make the count doing n as integer, n = totaltime(t)/time interval(dt)

    , but, how i do the loop and send at the sime time for the excel cells?

    Thursday, June 21, 2018 7:39 PM

All replies

  • Hello,

    Before anyone can assist you need to indicate

    • What type of excel file .xls, .xlsx or perhaps both ?
    • Are you using Excel automation, third party library ?
    • Not sure what you mean by "sime" time (same ?) ?

    In regards to bullet two, if you have not selected a method, consider looking at SpreadSheetLight (free Excel library), I have code samples here (but this is not a solution but instead a method to work with Excel)

    Honestly your description is partly but fully clear in what you are after so please take your time explaining things.


    Please remember to mark the replies as answers if they help and unmark them if they provide no help, this will help others who are looking for solutions to the same or similar problem. Contact via my Twitter (Karen Payne) or Facebook (Karen Payne) via my MSDN profile but will not answer coding question on either.
    VB Forums - moderator
    profile for Karen Payne on Stack Exchange, a network of free, community-driven Q&A sites

    Thursday, June 21, 2018 9:36 PM
    Moderator