Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > microsoft.public.excel.programming > #108881

Re: Modify Code to loop back through table after its been updated and process it

From GS <gs@v.invalid>
Newsgroups microsoft.public.excel.programming
Subject Re: Modify Code to loop back through table after its been updated and process it
Date 2016-06-05 20:06 -0400
Organization A noiseless patient Spider
Message-ID <nj2eqi$k2k$1@dont-email.me> (permalink)
References <TimLeonard.119a37a8@excelbanter.com>

Show all headers | View raw


>   Set XlSheet = Nothing
>   Set XlWorkbook = Nothing
>   Set Xl = Nothing

This is duplicate code that could be inside your Exit_Sub label 1x 
only.

You can 'dump' an entire range into a variant in 1 shot...

  Dim vAttrData

 I switched to using SolidWorks in 1998 and so I can't recall how you'd 
load an entire Acad Attribute Table into a VBA variable in 1 shot, or 
vice versa. (Seems we used a text file source, perhaps?)

To go from a worksheet to the variable...

  vAttrData = XlSheet.UsedRange

..which results a 2D array equal to the num rows/cols of data on the 
worksheet.

Similarly, you could load your Attribute Table into an array and 'dump' 
it into the worksheet in 1 shot.(Note that this needs to be a 2D array 
for all to work smoothly!)

-- 
Garry

Free usenet access at http://www.eternal-september.org
Classic VB Users Regroup!
  comp.lang.basic.visual.misc
  microsoft.public.vb.general.discussion

---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus

Back to microsoft.public.excel.programming | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Modify Code to loop back through table after its been updated and process it TimLeonard <TimLeonard.119a37a8@excelbanter.com> - 2016-06-05 20:21 +0100
  Re: Modify Code to loop back through table after its been updated and process it GS <gs@v.invalid> - 2016-06-05 20:06 -0400
    Re: Modify Code to loop back through table after its been updated and process it TimLeonard <TimLeonard.119b6d08@excelbanter.com> - 2016-06-06 18:27 +0100
      Re: Modify Code to loop back through table after its been updated and process it GS <gs@v.invalid> - 2016-06-06 14:42 -0400
        Re: Modify Code to loop back through table after its been updated and process it TimLeonard <TimLeonard.119bc168@excelbanter.com> - 2016-06-06 23:54 +0100
          Re: Modify Code to loop back through table after its been updated and process it GS <gs@v.invalid> - 2016-06-06 23:41 -0400
          Re: Modify Code to loop back through table after its been updated and process it GS <gs@v.invalid> - 2016-06-07 12:42 -0400
            Re: Modify Code to loop back through table after its been updated and process it TimLeonard <TimLeonard.119d5938@excelbanter.com> - 2016-06-08 05:34 +0100
              Re: Modify Code to loop back through table after its been updated and process it GS <gs@v.invalid> - 2016-06-08 03:46 -0400
              Re: Modify Code to loop back through table after its been updated and process it GS <gs@v.invalid> - 2016-06-08 13:45 -0400
                Re: Modify Code to loop back through table after its been updated and process it GS <gs@v.invalid> - 2016-06-08 13:55 -0400
                Re: Modify Code to loop back through table after its been updated and process it TimLeonard <TimLeonard.119e8e98@excelbanter.com> - 2016-06-09 03:45 +0100

csiph-web