getting writable table objects of a document

Hi,

I want to change some properties of all the tables in a document, but I 
don't know how to get writable objects of tables from the document.

0
Utf
4/8/2010 7:12:01 AM
word.vba.general 1023 articles. 1 followers. Follow

1 Replies
881 Views

Similar Articles

[PageSpeed] 34

mjlaali wrote:
> Hi,
>
> I want to change some properties of all the tables in a document, but
> I don't know how to get writable objects of tables from the document.

    Dim myTable As Table

    For Each myTable In ActiveDocument.Tables
        ' do something with myTable, for instance:
        myTable.Columns(1).Width = InchesToPoints(1.5)
    Next

-- 
Regards,
Jay Freedman
Microsoft Word MVP        FAQ: http://word.mvps.org
Email cannot be acknowledged; please post all follow-ups to the newsgroup so 
all may benefit. 


0
Jay
4/8/2010 3:57:39 PM
Reply:

Similar Artilces:

Where is Microsoft Map, I can't find it in the Insert Object menu
I can't find Microsoft Map in Excel 2003 See this Knowledgebase article: http://support.microsoft.com/default.aspx?scid=kb;en-us;277606 "Tony Dooley" wrote: > I can't find Microsoft Map in Excel 2003 ...

Pivot table formulas
Hi, I am trying to create a calculated field in a pivot table but cannot get the expression to work correctly. I have a field called Class Description and I need to perform a COUNT function on it. I have entered =COUNT('''Class Description''') as the formula but Excel always returns 1. Does anyone have any ideas how I can resolve this please? Hi Alan if its a text field then excel will automatically "count" it when you drag it into the data area - or am i completely misunderstanding what you're after. Cheers JulieD "Alan Bentley" <...

i want to use Miscrosoft Visio object Modal in VB 6
hi all Any one tell me from where i get the information actually i want to create an application using the microsfot Visio to create a digram in my application using visio builtin object any idea how can i do this Thanks in advanced Regards khurram try here http://msdn.microsoft.com/library/en-us/devref/html/dvs_00_preface_535.asp?frame=true and then download the v2003 sdk for examples Al "Syed Khurram Alam" <khurram.alam@eintelligencesoft.com> wrote in message news:uZKz3N6rEHA.3288@TK2MSFTNGP12.phx.gbl... > hi all > > Any one tell me from where i get the infor...

Is there some kind of color reference table for values?
Hi, Im using a flexgrid that lets me set fillcolors etc... i saw some code that defined some colors but i wanted to know if there was a chart so i can figure out my own colour schemes.. the code was... Const conCream As Long = 13303807 Const conNavy As Long = 8404992 Const conPaleGreen As Long = 13434828 Const conLightBlue As Long = 16760445 thanks On Tue, 23 Oct 2007 21:49:15 +0100, "Craig Armitage" <craig@icarmitage.co.uk> wrote: >Hi, > >Im using a flexgrid that lets me set fillcolors etc... > >i saw some code that defined some colors but i wanted to...

Problem with Excel getting correct # of records back from Access
I have a qry in MSAccess that brings me 1316 rows, but when I go to excel and run the qry it only gives me 692 rows. It look like it isn't making it to the 2nd statement or the "Or" statement in the query. Looking at the data in Excel. I can't remember how to get this to pass all the records over to Excel. Here's my "Having" part in the Qry: HAVING ((([Tracking].[Type of Case])="Expedited" Or ([Tracking].[Type of Case])="Fast Track" Or ([Tracking].[Type of Case])="Standard Pre-Service") AND (([Tracking].[Appeal or Gr...

Excel 2002 Pivot Table Newsgroup
This is a multi-part message in MIME format. ------=_NextPart_000_0017_01C596A9.0B0BF6A0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Is there an Excel Pivot Table newsgroup or is it the one with excel = formulas/worksheet functions? ------=_NextPart_000_0017_01C596A9.0B0BF6A0 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML><HEAD> <META http-equiv=3DContent-Type content=3D"text/h...

Get $5 Now
<HTML> <HEAD> <META NAME="GENERATOR" Content="Microsoft DHTML Editing Control"> <TITLE></TITLE> </HEAD> <BODY> <P>&nbsp;</P> </BODY> </HTML> ...

Why do I get the message that MSVCR80.dll is missing?
I have just loaded MS Office 2007 on my system and am trying to get Outlook going but it says that MSVCR80.dll is missing. Any suggestions on how to overcome that? Thank you! Take your pick - however, it is usually related to Symantec: http://www.google.com/search?sourceid=3Dnavclient&ie=3DUTF-8&rls=3DGGLG,G= GLG:2006-15,GGLG:en&q=3DMSVCR80%2edll+is+missing=20 --=81 Milly Staples [MVP - Outlook] Post all replies to the group to keep the discussion intact. All unsolicited mail sent to my personal account will be deleted without reading. =20 After furious head scratching, Gr...

adding new records from one table to an existing table
I'm pretty new to access so please bear with me. This may be really simple. I have a table listing thousands of existing stores. In the existing table i have a lot of geographic information including lat/ long, address, etc. Periodically I will need to add new records from another table. However, in the new table the field names aren't identical. ie....in the original table i have Original Address 1 and in the new table it says Address 1. I also don't have all the fields in the new table. So i need to add in the new records with their corresponding fields(i will fill in the mi...

Pivot Table (blank) Cells
Can I remove the '(blank)' entry that appears in pivot table cells that have no contents? Thanks Select one of the cells with (blank) in it. Hit the space bar and hit enter. This is really replacing the (blank) with a single space character. koala824 at Comcast wrote: > > Can I remove the '(blank)' entry that appears in pivot table cells that have > no contents? Thanks -- Dave Peterson Pretty slick. Works great, even if I cannot follow the programming logic of it all. My mindset never considered actually editing the contents of a pivot ...

multiple charts from a single pivot table
Hi can i create several pivot charts from a single pivot table? Nope. -- Best Regards, Luke M *Remember to click "yes" if this post helped you!* "Yossi evenzur" wrote: > Hi > can i create several pivot charts from a single pivot table? No, but you can copy the pivot table to create another which uses the same pivot cache, so they will refresh in synch with each other, and share any grouping and calculated fields. Filtering won't be synchronised though, so you may want to either automate that with macros or use formaulas to check for bas...

Double clicking in a Pivot Table, Please HELP
Hi! You know when you double clik in a field in a pivot table it shrinks down and everything right to that field isn't visible any more, only the total of that field which you double clicked is visible. I hope you will understand me because my english isn't good. So I have in My pivot table four columns: Year, Month, Model, and Price and in the data area i have some total. I have only Year 2005 and when i double click on it in shrinks, and i can only see the total for 2005. I have all the months(1-12) and when i double click on January it shrinks but the other eleven months don't...

Tabs within table cells
Hi, folks. I am having trouble setting tab stops within a table cell. I set the tabs, use option-tab to move text, and then the text moves with no seeming relation to the tabs. I've checked paragraph alignment, and everything else I can think of. I'm using Office X. Anybody got any ideas? Thanks, all. Jeff ...

Pivot Table Sort Issue
Hi Using Excel 2003 and the field Month (Jan....Dec), moved into the Row area. Been working fine (special month sort order) for months. Now the months do now sort "correctly" (Jan....Dec), but sorts Jan...Dec with May and Jun in the last 2 positions. All other 10 months sort correctly. ? thanks, Gene:) Maybe its a data issue -- text dates/real dates ? Check the recent data. Ensure all are real dates. -- Max Singapore --- "Gene Moirao" wrote: > Using Excel 2003 and the field Month (Jan....Dec), moved into the Row area. > Been working fine (speci...

Creating resizing macro
Hi, I'm trying to create a macro in Excel so that I can click onto a chart and resize it without having to select the "Select Objects" arrow in the drawing toolbar (this is for very PC illterate folk). I recorded the macro and got this text: Sub Chart_two_third_width() ' ' Chart_two_third_width Macro ' Macro recorded 03/04/2008 by IT ' ' ActiveSheet.Shapes("Chart 1").Select Selection.ShapeRange.LockAspectRatio = msoFalse Selection.ShapeRange.Height = 178.5 Selection.ShapeRange.Width = 340.5 With Selection .Placement ...

The ever annoying tables... Lock column width?
Trying to do up a catalog in Pub XP. I'm trying to put all the products into columns but when I shrink the table from the right all the columns shrink accordingly. I'm trying to fix column widths to fit a certain area, and this is really screwing me up. Why don't the columns in Publisher work the same as FrontPage? I will have to settle on text boxes, but that is an annoyance. Marc Place your cursor on a cell line, it will change into the re-sizer cursor. Fool around long enough and you will get the hang of it. Publisher is a breeze compared to FrontPage. -- Mary Saue...

Seems Simple But I Cant Get It !
THIS IS MY PROBLEM: i got a row with alpha_num entries(e.g RN1, P2, EN4) i wan to count the number of entries that has the number 1 behind the first two alphabet. -- cjjoo ------------------------------------------------------------------------ cjjoo's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=26916 View this thread: http://www.excelforum.com/showthread.php?threadid=471016 Hi! Try this: =SUMPRODUCT(--(MID(A1:F1,3,1)="1")) Biff "cjjoo" <cjjoo.1w07ab_1127801106.0035@excelforum-nospam.com> wrote in message news:cjjoo.1w07a...

Method 'OnTime' of object'_Application failed
Can anyone tell me why I get the following error when running the code below? Method 'OnTime' of object'_Application failed I have the following items in a public module Public Const cRunIntervalSeconds = 30 'Time interval for pulling updated data from Calendar (in seconds) Public Const cRunWhat = "TheSub" ' the name of the procedure to run Public Const SPLASH_MINUTES = 1 'Time interval for the Close Splash screen (in minutes) Public Const NUM_MINUTES = 100 'Time interval for closing the workbook(in minutes) Public bSELCTIONCHANGE...

multiplication table
is there a way to automaticly fill in a multiplication table? In Cells A2 to A13 I have 1, 2, 3...11,12. I then have 1 in B1, 2 in C1, 3 in D1, etc. Or in other words, numbers 1-12 going down column A (starting at A2) and numbers 1-12 going across row 1 (starting at B1). Is there a way to fill this entire thing in with one formula and dargging? I know "=A$2*B1" will work for the entire row, but not the whole table. Thanks guys, Robbi =$A2*B$1 will work for the whole table. On Wed, 2 Mar 2005 20:21:02 -0800, "Robbi777" <Robbi777@discussions.microsoft.c...

My objects are disappearing!
As soon as I draw an object in my chart and click off it, it vanishes. I know there was someone else with this same problem and it sort of resolved itself when she re-booted. This has been going on for me for months and I reboot every day. I go to Format Autoshape and it appears as if White is selected in the Fill and Line color boxes. I change that to a different color (e.g. blue) but as soon as I select that color and the color selection box collapses again, it shows white again. When I click on the drop down arrow to reselect the color, it shows that the color is already selecte...

Querying a Linked table
Hi: I am trying to do this: SELECT * FROM MySybaseLinkedTable WHERE dtDateTimeField > (SELECT MAX(dtDateTimeField) FROM MyAccessTable) When I run this query without the subselect and manually put the date in like #5/26/2007# then the query comes back immediately. When I try to do the above it crashes Access. Is what I am trying to do possible? If not, what is the best way to get a MAX value from an Access table and pass it into the linked table query? Thanks, Kayda On 28 May 2007 21:35:36 -0700, Kayda <blairjee@gmail.com> wrote: >Hi: > >I am trying to do this: > &g...

Windows Explorer problems with Office 2007 documents (read only)
Some Office 2007 Documents [compatibilty Mode] Opens as 'Read Only' Rename + Saving not allowed -"already open in other application" Checked document properties -Read Only NOT set Closing and re-opening Windows Explorer sometimes works, other times Laptop must be restared, Explorer re-opened, then the Document can be Renamed, Deleted, Saved, Moved or Opens OK - sometimes If I save as a differnt name = OK, but to delete the old file I have to re-start Explorer or the PC -very frustrating as this doesn't always work either! If I use another File Manager (Paper ...

Copying excel chart to word document without gridlines
I would like to capy an excel chart to a word document and not have gridlines show up in the word doc. The chart has a .tif header attached and the antire thing will need to be resized bacause I am going from a landscape format in excel to a portrait format in word. Both excel and word are 2003 versions. Make the chart in Excel as close to the way it must look in Word. This means remove gridlines, and size it to fit. Sizing is easier for an embedded chart, if it's going over as a picture. - Jon ------- Jon Peltier, Microsoft Excel MVP Tutorials and Custom Solutions Peltier Technic...

How to get the default browser
Is the any way to get the default browser in a system? Is there any registry value to know that? I want to check that through program.... Thanks, Deep On 17 May 2007 06:12:22 -0700, deep <joydeep.ball@gmail.com> wrote: >Is the any way to get the default browser in a system? Is there any >registry value to know that? I want to check that through program.... Maybe it is: HKEY_CLASSES_ROOT HTTP shell open ddeexec Application HKEY_CLASSES_ROOT\HTTP\shell\open\ddeexec\Application MrAsm I think what Paul writes here still works... I am runni...

Should Globally Needed Objects be Members in Main Frame, Application, or be Global?
I have been making objects needed by my entire application members either the Main Frame ( main window derived from CMDIFrameWnd ) or the Application (derived from CWinApp ). To get to these members I use either GetMainWnd() or AfxGetApp() to get pointers I can access them with. Now I wonder if there is any reason not to make these objects global so the use of GetMainWnd() or AfxGetApp() can be dispensed with. What are the the relative merits of putting objects needed globally for the duration of program execution in these three places? I typically create a singleton or static class...