|
HI
I am using iTextSharp - table control to create tables.
I was able to add 2 inner tables to an outer table by:
m_OuterTable = new Table(columns, rows)
{
Width = 100,
Cellpadding = 2,
BorderWidth =0
};
m_InnerTable1 = new Table(columns, rows)
{
Width = 80,
Cellpadding = 2
};
m_InnerTable2 = new Table(columns, rows)
{
Width = 80,
Cellpadding = 2
};
m_Outertable.InsertTable(m_InnerTable1);
m_Outertable.InsertTable(m_InnerTable2);
document.Add(m_OuterTable);
When I do the above the two inner tables touch each other. I would like to add a few space between them so that they look like two different tables, rather than 4 columns as it looks now.
Thanks in advance
BV
|
|
|
|
|
I'm sure there are plenty of people who can tell by looking at it...but what language am I looking at?
|
|
|
|
|
Hi,
I am using ITextSharp tables, in C#.
Thanks in advance
|
|
|
|
|
I would like to know how to capture the current position of the cursor within a textbox, and then if necessary how to place within the text area to change the text insertion point.
Thanks,
Leo T. Smith
Program/Analyst Supervisor
|
|
|
|
|
Hi,
Just out of curiosity, does it matter in what order the javascript, stylesheets and metatags appear on the web page?
Is this acceptable:
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link rel="stylesheet" type="text/css" href="Includes/Stylesheets/mystyles1.css" />
<meta name="robots" content="index,follow" />
<link rel="stylesheet" type="text/css" href="Includes/Stylesheets/mystyles2.css" />
The reason why I aqsk is because I have a master page which has styles needed across all web pages, but some pages require additional styles, and it seems as if .NET appends to the last one instead of grouping all the meta tags or stylesheets.
Brendan
|
|
|
|
|
I don't think there is any issue with the Sequence
|
|
|
|
|
The stylesheet order is relevant; they're called cascading style sheets because of that. You can declare a style for all pages first in the order, then apply styles to override the general style afterwards in each page, as needed. I believe that inline styles will add further refinement by temporarily overriding all page style sheets, but I've never tested that. You might experiment with that a bit, and if that works, it would be neater to do the page-specific styles inline and leave only those styles applicable to the entire site in the HEAD region.
"A Journey of a Thousand Rest Stops Begins with a Single Movement"
|
|
|
|
|
Hi all,
I am working on a project where i need to download a file from a server to a specified local location and open it localy from its native application by clicking one button and then upload it by one click also without any interactive interface.
i found that the best way is to build a com object and embed it inside an aspx page to be used as an IE addon to communicate with local storage for the client.
so please can you provide help about how to do it. or if there is any other solution please help me it is urgent.
Mohamad Abdou
|
|
|
|
|
google for 'activeX', that's what the COM object is called. This will only work with IE, a Java applet will work with FF, etc.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
Hi All
I have a webmethod that I would like to step through it, I call it from a web application.
I have a break point on the line that calls the webmethod and another one on the signature of the webthod in the webservice.
When I try to step into this web method I get the following error.
"Unable to automatically step into the server. The remote procedure could not be debugged. This usually indicates that debugging has not been enabled on the server."
Would you please assist me, I need know to get thi ssorted as soon as possible.
I just want to know how togo abount resolving this issue.
Thank you in advance.
MP
MP
|
|
|
|
|
You don't need the breakpoint on the line that calls the webmethod. Just attach to your process running your web service and stick a breakpoint in there.
|
|
|
|
|
Alright I have a .php document that lists the results from a query into a table, and has some controls above the table that allow me to make changes to entries if something isn't quite right. Here is the CSS:
body {
background-color: #cccccc;
}
#changeStatus {
font-family: arial, helvetica, sans-serif;
font-size: 0.6em;
position: absolute;
left: 2em;
top: -10em;
}
#changeUser {
font-family: arial, helvetica, sans-serif;
font-size: 0.6em;
position: absolute;
left: 28em;
top: -10em;
}
#changeRequired {
font-family: arial, helvetica, sans-serif;
font-size: 0.6em;
position: absolute;
left: 55em;
top: -10em;
}
#changeRequested {
font-family: arial, helvetica, sans-serif;
font-size: 0.6em;
position: absolute;
left: 86em;
top: -10em;
}
#itlisttableadmin {
font-family: arial, helvetica, sans-serif;
font-size: 0.8em;
position: absolute;
left: 0em;
top: 8em;
}
th {
font-family: arial, helvetica, sans-serif;
font-size: 0.8em;
color: maroon;
}
td {
font-family: arial, helvetica, sans-serif;
font-size: 0.8em;
}
IE of course garbles it up just because it's IE, but it works just fine in Opera. Everything looks exactly how it should. When I open the page in Firefox, the font-family and font-size for the #change sections work fine, but the positioning doesn't. All the other parts of the CSS work.
Can someone tell me what I'm doing wrong? The CSS statement is called in the PHP like this echo "<link rel="stylesheet" type="text/css" href="admincss.css" />"; .
|
|
|
|
|
I don't see any errors in the css code, but without knowing where the elements are in relation to the table it's hard to say if it makes sense or not...
Despite everything, the person most likely to be fooling you next is yourself.
|
|
|
|
|
They are supposed to be above the table and across the top like this
http://i30.photobucket.com/albums/c305/m450n/opera.jpg
But in Firefox they look like this
http://i30.photobucket.com/albums/c305/m450n/firefox.jpg
Do you need to see any pieces of the PHP code itself or would that make a difference?
|
|
|
|
|
The identifiers are case sensetive, are the id:s of the elements exactly as you have written in the css? Some browsers ignore this rule and matches the identifiers as non case sensetive, which could explain why Opera applies the positioning but not Firefox.
I'm just guessing here... that's the best I can do without seeing any of the html code...
Despite everything, the person most likely to be fooling you next is yourself.
|
|
|
|
|
Yes I checked the cases, just to be sure I changed them to all lowercase in both places. No change in either browser.
The odd thing is that I have another table setup (one for the admins and one for the users) that shows up perfectly in both Opera and Firefox. It's written the exact same way and I can't figure out why it is that the admin one won't work when the regular user one does.
Suggestions on what to try next?
|
|
|
|
|
47_MasoN_47 wrote: Suggestions on what to try next?
Show some code.
Despite everything, the person most likely to be fooling you next is yourself.
|
|
|
|
|
<?php
// Connecting to MySQL and selecting the xxx database
include 'it-opendb.php';
// Authentication - not secure...needs work
$adminPass = $_REQUEST['adminPass'];
if ($adminPass == "xxx") {
// Retrieve data from xxx database - xxx table
$request = mysql_query("SELECT * FROM xxx") or die(mysql_error());
// CSS statment
echo "<link rel='stylesheet' type='text/css' href='admincss.css' />";
// Display retrieved data with while loop
echo "<div id='itlisttableadmin'>";
echo "<table border='1'>";
echo "<tr> <th>Case #</th> <th>User Name</th> <th>Date Requested</th> <th>Date Required</th> <th>Problem</th> <th>Status</th></tr>";
while($row = mysql_fetch_array($request)){
// Print out list of IT requests into a table
echo "<tr><td>";
echo $row['id'];
echo "</td><td>";
echo $row['userName'];
echo "</td><td>";
echo $row['dateRequested'];
echo "</td><td>";
echo $row['dateRequired'];
echo "</td><td>";
echo $row['problem'];
echo "</td><td>";
echo $row['status'];
echo "</td></tr>";
}
echo "</div>";
echo "<div id='changeStatus'>";
echo "<form id='adminStatus' action='adminStatus.php' method='post'>";
echo "<p><label for='case'>Case #: </label><input type='text' maxlength='4' name='case' id='case' /></p>";
echo "<p><label for='newStatus'>New Status: </label><input type='text' name='newStatus' id='newStatus' /></p>";
echo "<p><input type='submit' name='adminStatusSubmit' id='adminStatusSubmit' value='submit' />";
echo "</form>";
echo "</div>";
echo "<div id='changeUser'>";
echo "<form id='adminUser' action='adminUser.php' method='post'>";
echo "<p><label for='case'>Case #: </label><input type='text' maxlength='4' name='case' id='case' /></p>";
echo "<p><label for='newUser'>New User Name: </label><input type='text' name='newUser' id='newUser' /></p>";
echo "<p><input type='submit' name='adminUserSubmit' id='adminUserSubmit' value='submit' />";
echo "</form>";
echo "</div>";
echo "<div id='changeRequired'>";
echo "<form id='adminRequired' action='adminRequired.php' method='post'>";
echo "<p><label for='case'>Case #: </label><input type='text' maxlength='4' name='case' id='case' /></p>";
echo "<p><label for='newDRequired'>New Date Required: </label><input type='text' name='newDRequired' id='newDRequired' /></p>";
echo "<p><input type='submit' name='adminRequiredSubmit' id='adminRequiredSubmit' value='submit' />";
echo "</form>";
echo "</div>";
echo "<div id='changeRequested'>";
echo "<form id='adminRequested' action='adminRequested.php' method='post'>";
echo "<p><label for='case'>Case #: </label><input type='text' maxlength='4' name='case' id='case' /></p>";
echo "<p><label for='newDRequested'>New Date Requested: </label><input type='text' name='newDRequested' id='newDRequested' /></p>";
echo "<p><input type='submit' name='adminRequestedSubmit' id='adminRequestedSubmit' value='submit' />";
echo "</form>";
echo "</div>";
}
else {
echo "Wrong Password - Try again";
}
?>
|
|
|
|
|
Do you have a doctype, a html element, a head element and a body element, or is that all the code?
There are elements using implicit end tags as in XHTML, but the code is not at all valid XHTML.
There is no end tag for the table, which in itself may very well mess up the page.
Despite everything, the person most likely to be fooling you next is yourself.
|
|
|
|
|
That is all the code. Since it's PHP I didn't think about having a doctype and whatnot.
I'll make some changes and just see what happens. Thanks for the suggestion, even if it doesn't fix it at least that's one more step making the code more valid.
|
|
|
|
|
47_MasoN_47 wrote: That is all the code. Since it's PHP I didn't think about having a doctype and whatnot.
That means that what you are sending to the browser isn't even close to be a valid html document, or even an html document at all. The browsers makes their best to try to display it as html anyway, but you can't expect it to work properly.
To be an html document, the page has to have a html, head, title and body tag:
<html>
<head>
<title>Minimal</title>
</head>
<body>
A minimal html document.
</body>
</html>
Despite everything, the person most likely to be fooling you next is yourself.
|
|
|
|
|
Yeah I generally write valid XHTML 1.0 Strict, I just didn't think about it since it was inside PHP. I taught myself PHP and am still learning a lot. I have a strong feeling that is what the problem is. Over the weekend I'm going to go through each piece of this site and change it so that it's valid.
Thanks a lot for the suggestion, I never would have thought about the browser being so confused at what I was trying to display.
|
|
|
|
|
For the record, after adding the proper tags to the HTML generated by the PHP and putting the end tag on the tables it fixed the problem. Now Firefox and Opera are both displaying the page in the same way.
|
|
|
|
|
Hi to all!
I've got some stupid question but i just can't figure it out.
I've working with ASP.NET for some time but i never have to make web application with user roles. So i began to work and place login control, create few users and roles but then i stop because i didn't know how to make some components on page to be enable(or invisible) for one role and disable for other role. I search about the problem and only answer i found is that roles in asp.net is based on folder security. So when logged user is with role manager i redirect him to Managers\Sales.aspx but when logged user is with employee role i redirect him to Employee\Sales.aspx. And this two pages are different - some controls are enabled (or invisible).
So my question is - is this the only way to achieve or i can do it "stupid" way - check logged user role and with some "if" enable (or hide) some controls?
Sorry again i know that this is a stupid question but i have to ask
King Regards!
countNazgul
|
|
|
|
|
Watch these videos[^] for a start if you have not.
I use a combination of approaches. One is my menu system has role tags so various functions are not visible to some users. This is also supplemented with web.config files in subdirectories that control access to the subdirectory. This works where the whole page is restricted to a set of roles.
When you get down to single pages that need to be different for various roles, there are two approaches.
One is that I have code in Form.Load that hides/shows different panels/controls according to which roles a user is in.
The second is that I wrote a RolePanel control that subclasses the panel control, and hides itself if a user isn't in the specified roles. This makes it easier to do the security declaratively rather than writing code.
'Howard
|
|
|
|