Search Results

Search found 1829 results on 74 pages for 'cells'.

Page 4/74 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Hide/Show some HTML table cells individually and align the remaining cells as they belong to the same row [closed]

    - by Brian
    [Edited at the resquest of admins] The best way I can explain my problem is showning an example. I have the table that you can see on the link below (since I can't post images...), that ha a table head (blue) and four rows, whose cells are green and white in color. I just want the white cells to hide/show alternately by clicking on green cells, which would remain always visible as parent cells. After hiding white cells, the green ones should be aligned into the same row, as they would fit like tetris bricks. That's all, I think more clear is impossible. http://i.stack.imgur.com/3n3In.jpg (follow the link to see the image explanation) The table code: <table class="columns" cellspacing="0" border="0"> <tr> <td class="left" rowspan="2"> <div style="text-align:center;"></div> </td> </tr><tr><td class="middle"> <div id="detail_table_source" style="display:none"></div> <br> <table id="detail_table" class="detail"> <colgroup> <col style="width:20px;"> <col style="width:40px;"> <col style="width:70px;"> <col style="width:20px;"> </colgroup> <thead> <tr> <th width="88">Blahhh</th> <th width="211">BLAHH</th> <th width="229">BLAHH</th> </tr> </thead> <tbody> <tr class="parent" id="row123" style="cursor: pointer; " title="Click to expand/collapse"> <td bgcolor="#A6A4CC">Blahhh</td> <td bgcolor="#A6A4CC">blah blah </td> <td bgcolor="#A6A4CC">Blahh</td> </tr> <tr class="child-row123" style="display: none; "> <td rowspan="3" bgcolor="#5B5B5B">&nbsp;</td> <td>blah blah </td> <td>blah blah</td> </tr> <tr class="child-row123" style="display: none; "> <td>blah blah</td> <td>blah blah</td> </tr> <tr class="child-row123" style="display: none; "> <td>blah blah</td> <td>blah blah</td> </tr> <tr> <td bgcolor="#6B7A94" class="parent" id="row456" style="cursor: pointer; " title="Click to expand/collapse"><strong>Blahh</strong></td> <td bgcolor="#FFFFFF" class="child-cell456" style="display: none; ">blah blah</td> <td bgcolor="#FFFFFF" class="child-cell456" style="display: none; ">blah blah</td> </tr> <tr> <td rowspan="4" valign="top" bgcolor="#5B5B5B" class="child-row456" style="display: none; ">&nbsp;</td> <td bgcolor="#6B7A94" class="parent" id="cell456" style="cursor: pointer; " title="Click to expand/collapse">blah blah</td> <td bgcolor="#6B7A94" class="parent" id="cell456" style="cursor: pointer; " title="Click to expand/collapse">blah blah</td> </tr> <tr> <td class="child-cell456" style="display: none; ">blah blah</td> <td class="child-cell456" style="display: none; ">blah blah</td> </tr> <tr> <td class="child-cell456" style="display: none; ">blah blah</td> <td class="child-cell456" style="display: none; ">blah blah</td> </tr> </tbody> </table> The script to hide/show whole rows (this works because it is copied from another example): <script language="javascript"> $(function() { $('tr.parent') .css("cursor","pointer") .attr("title","Click to expand/collapse") .click(function(){ $(this).siblings('.child-'+this.id).toggle(); }); $('tr[@class^=child-]').hide().children('td'); }); </script> And the failed attempt at expanding/hiding individual cells: <script language="javascript"> $(function() { $('td.parent') .css("cursor","pointer") .attr("title","Click to expand/collapse") .click(function(){ $(this).siblings('.child-'+this.id).toggle(); }); $('td[@class^=child-]').hide().children('td'); }); </script>

    Read the article

  • How to find 2D grid cells swept by a moving circle?

    - by Nevermind
    I'm making a game based on a 2D grid, with some cells passable and some not. Dynamic objects can move continuously, independent of the grid, but need to collide with impassable cells. I wrote an algorithm to trace a ray against the grid, that gives me all cells that ray intersects. However, actual object are not point-sized; I'm currently representing them as circles. But I can't figure out an effective algorithm to trace a moving circle. Here's a picture of what I need: The numbers show in what order the circle collides with grid cells. Does anybody know the algorithm to find these collisions? Preferably in C#. Update The circle can be bigger than a single grid cell.

    Read the article

  • Non-functioning AutoFilter on Locked Cells in Office 2008 - works in Office 2007

    - by Sarcas
    I'm looking into a problem for someone, who works in a mixed OS environment. She has created an Excel spreadsheet in Office 2007 to act as a directory, with AutoFilter turned on for names, email addresses, departments etc. To make sure no one accidentally edits email addresses (for example), she has protected the work sheet. Accessing this worksheet on a PC running Excel 2007, everything runs as you'd expect. You can filter the sheet by any of the auto-filtered columns, and because the sheet is protected, the data integrity is guaranteed. However, if you access the sheet on a Mac running Excel 2008, you can't filter the columns. What's strange here is that the AutoFilter dropdown arrows do appear in each of the column headers as you would expect. It's just that nothing happens if you click on them. If you select one of the column header cells (say, 'First Name') and check the menu: Data-Filter, you can see that AutoFilter is ticked. As another datapoint, you also seem to be able to apply an Advanced filter to these rows on the protected sheets. Does anyone know why this might be? It seems to be a compatibility issue between Excel 2007/2008 (I know the codebase isn't the same), but I can't find any references to it in documentation or forums anywhere, and it would be good to know if there's a way around this. Thanks!

    Read the article

  • Adding space BETWEEN cells in TableCell()

    - by user279521
    My code is below. I want to add space between cells in tableCell() something the equivalent of <td></td>&nbsp;&nbsp;<td></td> I am NOT looking for cellpadding or cellspacing because they both add space between the left cell border and the left table border (wall); I want to add space between two CELLS, not the table and the cell; protected void Page_Init(object sender, EventArgs e) { Table tb = new Table(); tb.ID = "tb1"; for (int i = 0; i < iCounter; i++) { TableRow tr = new TableRow(); TextBox tbox = new TextBox(); tbox.ID = i.ToString(); TableCell tc = new TableCell(); tc.Controls.Add(tbox); tr.Cells.Add(tc); tb.Rows.Add(tr); } pnlScheduler.Controls.Add(tb); } Any ideas?

    Read the article

  • Graphical glitches when adding cells and scrolling with UITableView

    - by Daniel I-S
    I am using a UITableView to display the results of a series of calculations. When the user hits 'calculate', I wish to add the latest result to the screen. This is done by adding a new cell to a 'results' section. The UITableViewCell object is added to an array, and then I use the following code to add this new row to what is displayed on the screen: [thisView beginUpdates]; [thisView insertRowsAtIndexPaths:[NSArray arrayWithObject:newIndexPath] withRowAnimation: UITableViewRowAnimationFade]; [thisView endUpdates]; This results in the new cell being displayed. However, I then want to immediately scroll the screen down so that the new cell is the lowermost cell on-screen. I use the following code: [thisView scrollToRowAtIndexPath:newIndexPath atScrollPosition:UITableViewScrollPositionBottom animated:YES]; This almost works great. However, the first time a cell is added and scrolled to, it appears onscreen only briefly before vanishing. The view scrolls down to the correct place, but the cell is not there. Scrolling the view by hand until this invisible new cell's position is offscreen, then back again, causes the cell to appear - after which it behaves normally. This only happens the first time a cell is added; subsequent cells don't have this problem. It also happens regardless of the combination of scrollToRowAtIndexPath and insertRowsAtIndexPath animation settings. There is also a problem where, if new cells are added repeatedly and quickly, the new cells stop 'connecting up'. The lowermost cell in a group is supposed to have rounded corners, and when a new cell is added these turn into square corners so that there is a clean join with the next cell in the group. In this case, however, a cell often does not lose its rounded edges despite not being the last cell anymore. This also gets corrected once the affected area moves offscreen and back. This method of adding and scrolling would be perfect for my application if it weren't for these weird glitches. Any ideas as to what I may be doing wrong?

    Read the article

  • Moving UITableView cells and maintaining consistent data

    - by Mark F
    I've enabled editing mode and moving cells around to allow users to position table view content in the order they please. I'm using Core Data as the data source, which sorts the content by the attribute "userOrder". When content is first inserted, userOrder is set to a random value. The idea is that when the user moves a cell around, the userOrder of that cell changes to accomodate its new position. The following are problems I am running into while trying to accomplish this: Successfully saving the the new location of the cell and adjusting all changed locations of influenced cells. Getting the data to be consistent. For example, the TableView handles the movement fine, but when i click on the new location of the cell, it displays data for the old cell that used to be that location. Data of all influenced cells gets messed up as well. I know I have to implement this in: - (void)tableView:(UITableView *)tableView moveRowAtIndexPath:(NSIndexPath *)sourceIndexPath toIndexPath:(NSIndexPath *)destinationIndexPath {} I just don't know how. The apple docs are not particularly helpful if you are using Core Data, as in my situation. Any guidance greatly appreciated!

    Read the article

  • Animating the offset of the scrollView in a UICollectionView/UITableView causes prematurely disappearing cells

    - by radutzan
    We have a UICollectionView with a custom layout very similar to UITableView (it scrolls vertically). The UICollectionView displays only 3 cells simultaneously, with one of them being the currently active cell: [ 1 ] [*2*] [ 3 ] (The active cell here is #2.) The cells are roughly 280 points high, so only the active cell is fully visible on the screen. The user doesn't directly scroll the view to navigate, instead, she swipes the active cell horizontally to advance to the next cell. We then do some fancy animations and scroll the UICollectionView so the next cell is in the "active" position, thus making it the active one, moving the old one away and bringing up the next cell in the queue: [ 2 ] [*3*] [ 4 ] The problem here is setting the UICollectionView's offset. We currently set it in a UIView animation block (self.collectionView.contentOffset = targetOffset;) along with three other animating properties, which mostly works great, but causes the first cell (the previously active one, in the latter case, #2) to vanish as soon as the animation starts running, even before the delay interval completes. This is definitely not ideal. I've thought of some solutions, but can't figure out the best one: Absurdly enlarge the UICollectionView's frame to fit five cells instead of three, thus forcing it to keep the cells in memory even if they are offscreen. I've tried this and it works, but it sounds like an awfully dirty hack. Take a snapshot of the rendered content of the vanishing cell, put it in a UIImageView, add the UIImageView as a subview of the scrollView just before the cell goes away in the exact same position of the old cell, removing it once the animation ends. Sounds less sucky than the previous option (memory-wise, at least), but still kinda hacky. I also don't know the best way to accomplish this, please point me in the right direction. Switch to UIScrollView's setContentOffset:animated:. We actually used to have this, and it fixed the disappearing cell issue, but running this in parallel with the other UIView animations apparently competes for the attention of the main thread, thus creating a terribly choppy animation on single-core devices (iPhone 3GS/4). It also doesn't allow us to change the duration or easing of the animation, so it feels out of sync with the rest. Still an option if we can find a way to make it work in harmony with the UIView block animations. Switch to UICollectionView's scrollToItemAtIndexPath:atScrollPosition:animated:. Haven't tried this, but it has a big downside: it only takes 3 possible constants (that apply to this case, at least) for the target scroll position: UICollectionViewScrollPositionTop, UICollectionViewScrollPositionCenteredVertically and UICollectionViewScrollPositionBottom. The active cell could vary its height, but it always has to be 35 points from the top of the window, and these options don't provide enough control to accomplish the design. It could also potentially be just as problematic as 3.1. Still an option because there might be a way to go around the scroll position thing that I don't know of, and it might not have the same issue with the main thread, which seems unlikely. Any help will be greatly appreciated. Please ask if you need clarification. Thanks a lot!

    Read the article

  • Organising XML results as cells in container (AS3)

    - by PJ Palomaki
    Hi, I'm having some problems figuring out how to organise data pulled off XML in cells within a container. I'm sure this should be a basic thing in AS3, but my head's fried.. can anyone help? Basically an array if fed to callThumbs() which iterates through it and compares the entries with preloaded XML _my_images. If match is found, it's sent to processXML which loads all relevant info and loads a .jpg thumbnail. All this is then fed to createCell which creates a specific cell with position values depending on x_counter and y_counter values (4 cells in a row) and adds the cell into a container _container_mc. The Problem: This all works fine and looks fine, the problem is that the cells within the container do not display in descending order. They are in random order, probably because some of the .jpg's takes longer to load etc. How do I easily organise the cells within the container in descending order by the XML .id value? Or how do I tell Flash to wait till the thumbnail and data is loaded and the cell created and added? Thanks guys, would really appreciate all the help! PJ //Flash (AS3) function callThumbs(_my_results:Array):void { // selector = 1 for specific items, 2 for search items var _thumb_url:XML; for (var r:Number=0; r < _my_results.length; r++) { // iterate through results vector, compare with _my_images XML .id for (var i:Number=0; i < _my_images.length(); i++) { if (_my_images[i][email protected]() == _my_results[r]) { _thumb_url=_my_images[i]; processXML(_thumb_url, i); } } } } // End callThumbs function processXML(imageXML:XML, num:Number) { // Processes XML data and loads .jpg thumbnail var _thumb_loader=new Loader(); _thumb_loader.load(new URLRequest("thumbs/thumb_sm/" + imageXML.@id + "_st.jpg")); _thumb_loader.contentLoaderInfo.addEventListener(Event.COMPLETE,thumbLoaded); _thumb_loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, urlNotFound); var id:XMLList = new XMLList; id = imageXML.@id; var description:XMLList = new XMLList; description = imageXML.@description; function urlNotFound(event:IOErrorEvent):void { trace("The image URL '" + String(imageXML.@id) + "' was not found."); } function thumbLoaded(e:Event):void { var imageLoader:Loader = Loader(e.target.loader); var bm:Bitmap = Bitmap(imageLoader.content); createCell(bm, id, description, num); adjustFooterBar(); // Adjust bottom footer } } // End processXML private function createCell(_image:Bitmap, _id, _description:String, _position):void { // Creates a cell with data, add to container var _cell_mc = new CellTitle(); _cell_mc.initCell(_image, _id, _description, _position, x_counter, y_counter); if (x_counter+1 < 4) { x_counter++; } else { x_counter = 0; y_counter++; } _container_mc.addChild(_cell_mc); // movieclip container } // End createCell

    Read the article

  • Can I insert rows next to a locked column in Excel?

    - by Tom
    If I lock cells A1:A3000, is there a way to insert rows in columns B-Z? I highlight them and I don't get the option to insert even though it is selected in the lock options. (Bottom line is that I need column A static, not to move.) Any ideas? Is it even possible? Better yet, is there any way to have formulas in column A static, as I insert rows in column B? Column A formulas change cell location when I do so.

    Read the article

  • 16 bit processor , memory addressing and memory cells

    - by Zia ur Rahman
    Suppose the accumulater register of the processor is of 16 bit , now we can call this processor as 16 bit processor, that is this processor supports 16 bit addressing. now my question is how we can calculate the number of memory cells that can be addressed by 16 bit addressing? according to my calculation 2 to the power 16 becomes 65055 it means the memory have 65055 cells now if we take 1KB=1000 Bytes then this becomes 65055/1000=65.055 now this means that 65 kilo bytes memory can be used with the processor having 16 bit addressing. now if we take 1KB=1024 Bytes then this becomes 65055/1024=63.5 ,it means that 63 kilo bytes memory can be used with this processor, but people say that 64 kilo bytes memory can be used. Now tell me am i right or wrong and why i am wrong why people say that 64kb memory can be used with the processor having 16 bit addressing?

    Read the article

  • How can I "remind" users to fill in cells on a worksheet

    - by Allan
    Hello: I have a set of cells on a worksheet called "Docs". The cell range is (B13:C23). When users get taken to this page, they are meant to fill out each of these cells with a value from 0 through 6. My Question: Is there some code that I can attach to this sheet where, if a user does not fill in a cell with anything (ie. leaves it blank) and tries to leave the sheet or close the workbook, they are somehow reminded to fill it in? Or is there a way to not let them leave the sheet until it's completed? Thanks.. Allan

    Read the article

  • SQL count NULL cells

    - by Giuseppe
    Dear All, I have the following problem. I have a table in a db, with many columns. I can do different kind of select queries, to show, for example, for each record that satisfies a condition: all cells from columns with names ending in _t0 all cells from columns with names ending in _t1 ... To get the column lists to form the queries I use the information schema. Now, the problem: each query returns a record with a subset of the columns of the big table. This means that I can get a row of (all!) NULLs. How can I ask my query to reject such rows without having to type in explicitely the column names (i.e. by saying where col_1 is not null, col_2 is not null...)? Is it possible? Thanks in advance!!! Sep

    Read the article

  • UIWebView in UITableView hide cells

    - by Belkadam
    I have a UIWebView in UITableView, I have this on storyboard: The UIImageView is my future NavBar and the UIWebView is in the UITableView, I have this configuration: -UIImageView -UITableView -UIWebView -UITableViewCell When the UIWebView load the pages (I Have local pages) I want that it takes dynamically their size and for this I have this code: [detailWebView setFrame:CGRectMake(0.,0.,detailWebView.frame.size.width,[[detailWebView stringByEvaluatingJavaScriptFromString:@"document.body.scrollHeight;"] intValue])]; The problem is when the loaded page is long, my UIWebBrowser hide the cells and didn't push them to get cells at the bottom. I don't understand why I have this, when I resize the UIWebBrowser in the storyboard I don't have this problem but I want to do it programmatically Thanks,

    Read the article

  • Neglect empty cells while refreshing

    - by Ashok Vardhan
    I have an excel macro which refreshes the worksheet. However, if the file (in .csv format) with which the worksheet is being refreshed has empty cells, it's shifting the data from other columns and placing the data in wrong columns. However,if I manually refresh the sheet, it's working fine. I don't know how I can fix this. I just want my whole .csv file including empty cells to appear as it is in the worksheet. Any suggestions would be greatly helpful. The following is the Macro code. With Worksheets("RawData1").QueryTables(1) .TextFilePromptOnRefresh = False .RefreshStyle = xlinsertdelete .Connection = Application.Substitute(.Connection, CurrPath, NewPath) .Refresh End With // We can assume that we have CurrPath and NewPath properly

    Read the article

  • toggle the grid cells value, ASP.net 3.5

    - by user92027
    Hi For my web application, I want a 10*10 (100 cells which is created dynamically) grid to be displayed in the following manner. 0) Initially all the cells' color is green. 1) If i click on any cell its color becomes red if it is green and if i click again it becomes red.(Toggle the cell color) 2) I should be able to display dynamic number of link buttons in each cell.On the click of which it pop ups a window. Are there any control available for this? Or how can i implement this functionality. I am using ASP.net 3.5.

    Read the article

  • jQuery - OnClick, change background color for table cells

    - by andrew
    Hi all, Let me show you a demo: here it is working for only rows. its not working for cells. i want to change cells' (tds') background colors with mouse clicks. For example: a have a table, and it has 4 tds. table's background color is white. if i click to a td, a td should be red, than if i click to b, b td should be red and a td should be white again. if i click to c than, c should be red and b should be white right now. A - B C - D Can anyone help me?

    Read the article

  • Updating MS - Access fields through MS-Excel cells

    - by SpikETidE
    Hi everyone.... Consider that i have an excel workbook and an access table not necessarily having a similar structure (i.e. They may not have same number of columns) When i open the workbook the rows in the excel sheet get populated by the rows in access table (copied from the access table into the excel sheet's particular range of cells specified using macros). Then i modify certain cells in the excel sheet. I also have a button called "Save" in the excel sheet. When pressed, this will execute a macro. My question how can i update the access table to reflect the changes in the excel sheet when the save button is clicked...? Thanks for your time and suggestions...!

    Read the article

  • Search row with highest number of cells in a row with colspan

    - by user593029
    What is the efficient way to search highest number of cells in big table with numerous colspan (merge cells ** colspan should be ignored so in below example highest number of cells is 4 in first row). Is it js/jquery with reg expression or just the loop with bubble sorting. I got one link as below explainig use of regex is it ideal way ... can someone suggest pseudo code for this. High cpu consumption due to a jquery regex patch <table width="156" height="84" border="0" > <tbody> <tr style="height:10px"> <td width="10" style="width:10px; height:10px"/> <td width="10" style="width:10px; height:10px"/> <td width="10" style="width:10px; height:10px"/> <td width="10" style="width:10px; height:10px"/> </tr> <tr style="height:10px"> <td width="10" style="width:10px; height:10px" colspan="2"/> <td width="10" style="width:10px; height:10px"/> <td width="10" style="width:10px; height:10px"/> </tr> <tr style="height:10px"> <td width="10" style="width:10px; height:10px"/> <td width="10" style="width:10px; height:10px"/> <td width="10" style="width:10px; height:10px" colspan="2"/> </tr> <tr style="height:10px"> <td width="10" style="width:10px; height:10px" colspan="2"/> <td width="10" style="width:10px; height:10px"/> <td width="10" style="width:10px; height:10px"/> </tr> </tbody> </table>

    Read the article

  • DataGridView cells not editable when using an outside thread call

    - by joslinm
    Hi, I'm not able to edit my datagridview cells when a number of identical calls takes place on another thread. Here's the situation: Dataset table is created in the main window The program receives in files and processes them on a background thread in class TorrentBuilder : BackgroundWorker creating an array objects of another class Torrent My program receives those objects from the BW result and adds them into the dataset The above happens either on my main window thread or in another thread: I have a separate thread watching a folder for files to come in, and when they do come in, they proceed to call TorrentBuilder.RunWorkerAsynch() from that thread, receive the result, and call an outside class that adds the Torrent objects into the table. When the files are received by the latter thread, the datagridview isn't editable. All of the values come up properly into the datagridview, but when I click on a cell to edit it: I can write letters and everything, but when I click out of it, it immediately reverts back to its original value. If I restart the program, I can edit the same cells just fine. If the values are freshly added from the main window thread, I can edit the cells just fine. The outside thread is called from my main window thread, and sits there in the background. I don't believe it to be ReadOnly because I would have gotten an exception. Here's some code: From my main window class: private void dataGridView_DragDrop(object sender, DragEventArgs e) { ArrayList al = new ArrayList(); string[] files = (string[])e.Data.GetData(DataFormats.FileDrop); foreach (string file in files) { string extension = Path.GetExtension(file); if (Path.GetExtension(file).Equals(".zip") || Path.GetExtension(file).Equals(".rar")) { foreach (string unzipped in dh.UnzipFile(file)) al.Add(unzipped); } else if (Path.GetExtension(file).Equals(".torrent")) { al.Add(file); } } dataGridViewProgressBar.Visible = true; tb.RunWorkerCompleted += new RunWorkerCompletedEventHandler(tb_DragDropCompleted); tb.ProgressChanged += new ProgressChangedEventHandler(tb_DragDropProgress); tb.RunWorkerAsync() } void tb_DragDropCompleted(object sender, RunWorkerCompletedEventArgs e) { data.AddTorrents((Torrent[])e.Result); builder.Dispose(); dh.MoveProcessedFiles(data); dataGridViewProgressBar.Visible = false; } From my outside Thread while (autocheck) { if (torrentFiles != null) { builder.RunWorkerAsync(torrentFiles); while (builder.IsBusy) Thread.Sleep(500); } } void builder_RunWorkerCompleted(object sender, System.ComponentModel.RunWorkerCompletedEventArgs e) { data.AddTorrents((Torrent[])e.Result); builder.Dispose(); dh.MoveProcessedFiles(xml); data.Save(); //Save just does an `AcceptChanges()` and saves to a XML file }

    Read the article

  • Excel VBA : Changing string in cells

    - by user1265125
    I have cells with data like these: ABCD123XYZ MPOP345MLU . . . . What I want to do is, to remove the 3rd and 4th character from all these cells, hence giving AB123XYZ MP345MLU How do I do this in VBA? I have no idea about this language, and if someone can guide me in the right direction, it'd be great :) I understand I have to: 1. Declare 2 string variables st1 and st2 2. Store data from cell A1 into the variable st1 3. Copy all but the 2nd and 3rd char into str2 4. Output Str2 into B1 5. Move to A2

    Read the article

  • My table cells don't highlight immediately when touched

    - by Steve Denenberg
    Hi, In my app, I have a table view that has about eight cells. There is a navigation bar at the top. When a user touches a cell, nothing happens for about 1/2 second. Then the touched cell highlights blue and immediately the new view slides into position. The problem is that there is no feedback to the user about which cell he touched until just before the new view slides into position. For example, when I explore the tables in the iPhone's Settings application, when you touch a cell, the cell immediately turns blue, and then there is a 1/2 second delay, and then you see the new view. How do I get my table's feedback of highlighting the cells to happen immediately? I am using tableView didSelectRowAtIndexPath:, and each cell has an accessory button. Thanks for any insight.

    Read the article

  • vba: what does ReDim Preserve do and simple array question

    - by every_answer_gets_a_point
    i am looking at someone else's vba excel code. they are doing ReDim Preserve dataMatrix(7, i) in both loops. what does this do? also, it seems like the second loop just overwrites the data in the first, loop, is that correct? Dim dataMatrix() As String Worksheets.Item("ETS").Select Do While Trim(Cells(r, 1)) <> "" Debug.Print "The line: ", Trim(Cells(r, 1)), r r = r + 1 dataMatrix(1, i) = Trim(Cells(r, 1)) ''file name dataMatrix(2, i) = Trim(Cells(r, 2)) ''sample type dataMatrix(3, i) = Trim(Cells(r, 3)) ''sample name dataMatrix(4, i) = "ETS" '' dataMatrix(5, i) = Trim(Cells(r, 5)) ''Response dataMatrix(6, i) = Trim(Cells(r, 6)) ''ISTD Response dataMatrix(7, i) = Trim(Cells(r, 10)) ''Calculated Conc i = i + 1 ReDim Preserve dataMatrix(7, i) Loop r = 5 Worksheets.Item("ETG").Select Do While Trim(Cells(r, 1)) <> "" Debug.Print "The line: ", Trim(Cells(r, 1)), r r = r + 1 dataMatrix(1, i) = Trim(Cells(r, 1)) ''file name dataMatrix(2, i) = Trim(Cells(r, 2)) ''sample type dataMatrix(3, i) = Trim(Cells(r, 3)) ''sample name dataMatrix(4, i) = "ETG" dataMatrix(5, i) = Trim(Cells(r, 5)) ''Response dataMatrix(6, i) = Trim(Cells(r, 6)) ''ISTD Response dataMatrix(7, i) = Trim(Cells(r, 10)) ''Calculated Conc i = i + 1 ReDim Preserve dataMatrix(7, i) Loop

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >