Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Adjusting window width to table width
Message
 
 
À
02/08/2001 11:06:19
Information générale
Forum:
Internet
Catégorie:
Javascript
Divers
Thread ID:
00538712
Message ID:
00540071
Vues:
21
Hi!

There are several ways to access objects and their properties. There is a function that returns property value by property name. There are coillections of objects for document and for body. I guess the table object is defined inside of the body, so try to reference it from there.

BTW, you can get width of tbale from the style also.

>>>>>>Is there a way to adjust the window width based on the table width? The table width may vary based on the length of some fields. I would like the browser window to adjust based on it.
>>>>>
>>>>>In java script you can use self.resizeto(width,height) to set the window size. So if you set the table width to 'width=710' you should be able to use the same 710 in the java code self.resizeto(720,200).
>>>>
>>>>We do not know the table width. It's size may vary depending on the column content. I was looking mostly for a function such as Table.Width.
>>>
>>>That I have never done, but the Windows document object model should let you query for the value of the table width. Document.TableName.Width Where TableName is the name you gave your table. But that may be only for Internet Explorer and if you have netscape users then it may not work.
>>
>>Oh, that's cool. Let me try that.
>
>My table name is defined with FournierTransformationList so I use that at the end of the page to check its width:
>
>alert(document.FournierTransformationList.width)
>
>but I can't get it to work.
Vlad Grynchyshyn, Project Manager, MCP
vgryn@yahoo.com
ICQ #10709245
The professional level of programmer could be determined by level of stupidity of his/her bugs

It is not appropriate to say that question is "foolish". There could be only foolish answers. Everybody passed period of time when knows nothing about something.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform