|
Hi, i have an aspx page containing 7 user controls now i have 5 actors in my app , against each user i have certain function defined, now based on these function i have to either make a control's visibility true/false or enable/disable a control and the roles and the function corresponding to them r defined in an xml file.
i am not able to figure out how to go about it any help/suggestion are welcome
|
|
|
|
|
This is a snippet from my page:
I need some javascript that can check if the id query string is in the
action attribute, and if it is, remove it so the form element will look
like this:
Thanks.
/\ |_ E X E GG
|
|
|
|
|
You can use a regular expression like /(\?|&)id=(.*?)(&|$)/ to check for the attribute and remove it.
---
b { font-weight: normal; }
|
|
|
|
|
COM Error Number: -2147467259 (0x80004005)
Line Number: 97
Column Number: -1
Brief Description: Method '~' of object '~' failed
Can any one explain me what could be the possible reasons.
This code is generated when asp application is run, a call to specific file is causing the problem. a dll is also used in these pages,
when this application is run by below 5 hits its running fine. but when the load increased to 10 the error is generated
|
|
|
|
|
anybody plz send some dotnet projects with explanation its very urgent for me to get a job
|
|
|
|
|
Don't mind but what will you do with others projects??? Those projects will not help in your job but ya it will be very harmful for your carrier.
And though you want readymade .NET project then you can get it from this site itself. Just see up here is one green bar where .NET is mentioned. you just go from it.
And All the best for your job.
|
|
|
|
|
hiral_shah wrote: carrier
Career
Similar sound - very different meaning
|
|
|
|
|
Hi!
I have one global.asa file under root directory and I have defined a few application variables. Application("Visitors") keeps the total count for visitors. However, it is getting resetted every day. I wonder if it is caused because resetting the IIS.
If you enlighten me about it, I would really appreciate it.
Thanks!
Sub Application_OnStart
Application.Lock
Application("Visitors") = 0
Application("CurrentVisitors") = 0
Application.UnLock
End Sub
Sub Session_OnStart
Application.Lock
Application("CurrentVisitors") = Application("CurrentVisitors") + 1
Application("Visitors") = Application("Visitors") + 1
Application.UnLock
End Sub
Sub Session_OnEnd
Application.Lock
Application("CurrentVisitors") = Application("CurrentVisitors") - 1
Application.UnLock
End Sub
|
|
|
|
|
A web application does not run continuiously. Whenever the web server determines that the application is unused, or if it thinks that recycling it would free resources that is better used elsewhere, it can shut the application down. The application will start again at the first request to the site.
Some servers are also set up to recycle the applications on a regular interval.
If the IIS is restarted due to some server problems, the web applications will of course also be shut down.
---
b { font-weight: normal; }
|
|
|
|
|
Hi There,
I have a problem to create multi level tree structure of the folder in php if you know how then please please reply me as soon as possible. It will help me a lot. I want the same structure as like we got while we open my computer and click on folders from standard button bar.
Waiting for the Reply,
Thank you in advance.
|
|
|
|
|
Would it be possible to make a web service request so that when it returns the data it returns straight XML instead of the serialized object? And if so, how do I do it?
I am quite new to this... thanks for your time!
|
|
|
|
|
A web service returns a SOAP message, which is XML that follows the SOAP standard.
If you make a regular web page instead, you can return anything you like.
---
b { font-weight: normal; }
|
|
|
|
|
After some playing around I realized that I'm an idiot haha
I was able to figure it out
|
|
|
|
|
Morning all.
Im currently working on a booking form and need to get the user to input, into two ASP textboxes, the date they want to arrive and the date they want to depart. To make it easier for the user when they click on the textbox an asp:calendar control appears. The calendar is hidden using css and the onfocus feature of the textbox is used to make it visible again. The javascript performs this by editing the calendars css display attribute.
The user can then select a date and the date gets thrown into the textbox. So thats all gravy.
The problem appears when the month selector is clicked on the calendar control, because of course this reloads the page and thus sets the calendars css back to it's original setting. Thus hiding the calendar control.
How can I get around this? Is there a better way of doing this.
My only other option is to have a link to the side of the textbox and reveal the calendar on that being clicked. But id rather use the onfocus event of the textbox and keep the form simpler...
Any help on this would be spot on. Thanks
|
|
|
|
|
Personally, my favorite way to popup a helpful calendar is to open a new window using javascript. This new window has JUST the calendar and the name of the textbox that it needs to set a value for is passed in the url. Then, to set up the calendar to update that textbox on the other window I add this code:
Note: calPicker is my Calendar control
Protected Sub calPicker_DayRender(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.DayRenderEventArgs) Handles calPicker.DayRender
' Clear the link from this day
e.Cell.Controls.Clear()
' Add the custom link
Dim Link As New HyperLink
Link.Text = e.Day.Date.Day
'Format colors
If e.Day.IsOtherMonth Then
Link.ForeColor = Drawing.Color.DimGray
Else
Link.ForeColor = Drawing.Color.Black
End If
Link.ToolTip = e.Day.Date.ToString("MMMM d, yyyy")
'Tell the link which control on the other window to update
Link.Attributes.Add("href", "JavaScript:window.opener.document." & Request.QueryString("field") & ".value = '" & e.Day.Date.ToString("yyyyMMdd") & "'; window.close();")
e.Cell.Controls.Add(Link)
End Sub
You can still do it your way if you want, you will just have to setup a bunch of flag variables to check and see if you are supposed to hide the css or not, and you can also use hidden fields on the aspx side, and javascript.
Hope this helps.
|
|
|
|
|
Hi All! I want to get some link regarding accessing MS Word (through automation ) from javascript.(just like vb6 or vbscript allows). I need javascript as it is supported by all major browsers.
Thanks
|
|
|
|
|
Hi,
I have one problem with nested tables. following is spinpet for html
<code>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title>Untitle</title>
</head>
<body>
<div>
<table style="width:100%" border="0" width="100%" cellpadding="2" cellspacing="2">
<tr class="TableRowBackGround">
<td>
<table style="width:100%" cellspacing="0" border="1" style="border-color:Black;border-width:1px;border-style:solid;width:100%;border-collapse:collapse;">
<tr>
<td >
<span >Root</span></td>
<td > pqr</td>
<td >0</td>
<td align="center" >
4</td>
<td align="center" >
1</td>
</tr>
<tr>
<td colspan="12" style="border-style:Solid;width:100%;">
<table style="width:100%" border="0" style="border-color:Black;border-width:1px;border-style:solid;width:100%;border-collapse:collapse;">
<tr>
<td></td>
<td>
<table style="border-color:Black;border-width:1px;border-style:solid;width:100%;border-collapse:collapse;" cellspacing="0" border="0" >
<tr>
<td >
<span >BBB</span></td>
<td >
xxx</td>
<td >
1</td>
<td align="center" >
2</td>
<td align="center" >
2</td>
</tr>
<tr>
<td colspan="6" style="border-style:None;width:100%;">
<table style="width:100%" border="0" style="border-color:Black;border-width:1px;border-style:solid;width:100%;border-collapse:collapse;">
<tr>
<td></td>
<td>
<table style="width:100%" cellspacing="0" border="0" >
<tr>
<td colspan="12" style="border-style:None;width:100%;">
<table style="width:100%" border="0" style="border-color:Black;border-width:1px;border-style:solid;width:100%;border-collapse:collapse;">
<tr>
<td>
</td>
<td>
<table style="width:100%" cellspacing="0" border="0" >
<tr>
<td ><span >AAA</span></td>
<td > xyz</td>
<td >0</td>
<td align="center" >0</td>
<td align="center" >4</td>
</tr>
<tr>
<td colspan="12" style="border-style:None;width:100%;">
<table style="width:100%" border="0" style="border-color:Black;border-width:1px;border-style:solid;width:100%;border-collapse:collapse;">
<tr>
<td></td>
<td>
<table style="width:100%" cellspacing="0" border="0" >
<tr>
<td ><span >Chart</span></td>
<td > xyz</td>
<td >0</td>
<td align="center" >0</td>
<td align="center" >5</td>
</tr>
<tr>
<td colspan="12" style="border-style:None;width:100%;">
<table style="width:100%" border="0" style="border-color:Black;border-width:1px;border-style:solid;width:100%;border-collapse:collapse;">
<tr>
<td></td>
<td>
<table style="width:100%" cellspacing="0" border="0" >
<tr >
<td ><span >Level 6</span></td>
<td > abc</td>
<td >0</td>
<td align="center" >0</td>
<td align="center" >6</td>
</tr>
<tr>
<td colspan="12" style="border-style:None;width:100%;">
<table style="width:100%" border="0" style="border-color:Black;border-width:1px;border-style:solid;width:100%;border-collapse:collapse;">
<tr>
<td></td>
<td>
<table style="width:100%" cellspacing="0" border="0" >
<tr >
<td ><span >Level 7</span></td>
<td > abc</td>
<td >0</td>
<td align="center" >0</td>
<td align="center" >7</td>
</tr>
<tr>
<td colspan="12" style="border-style:None;width:100%;">
<table style="width:100%" border="0" style="border-color:Black;border-width:1px;border-style:solid;width:100%;border-collapse:collapse;">
<tr>
<td></td>
<td>
<table style="width:100%" cellspacing="0" border="0" >
<tr >
<td ><span >Level 8</span></td>
<td > abc</td>
<td >0</td>
<td align="center" >0</td>
<td align="center" >8</td>
</tr>
<tr>
<td colspan="12" style="border-style:None;width:100%;">
<table style="width:100%" border="0" style="border-color:Black;border-width:1px;border-style:solid;width:100%;border-collapse:collapse;">
<tr>
<td></td>
<td>
<table style="width:100%" cellspacing="0" border="0" >
<tr >
<td ><span >Level 9</span></td>
<td > abc</td>
<td >0</td>
<td align="center" >0</td>
<td align="center" >9</td>
</tr>
<tr>
<td colspan="12" style="border-style:None;width:100%;">
<table style="width:100%" border="0" style="border-color:Black;border-width:1px;border-style:solid;width:100%;border-collapse:collapse;">
<tr>
<td></td>
<td>
<table style="width:100%" cellspacing="0" border="0" >
<tr >
<td ><span >Level 10</span></td>
<td > abc</td>
<td >0</td>
<td align="center" >0</td>
<td align="center" >10</td>
</tr>
<tr>
<td colspan="12" style="border-style:None;width:100%;">
<table style="width:100%" border="0" style="border-color:Black;border-width:1px;border-style:solid;width:100%;border-collapse:collapse;">
<tr>
<td></td>
<td>
<table style="width:100%" cellspacing="0" border="0" >
<tr >
<td ><span >Level 11</span></td>
<td > abc</td>
<td >0</td>
<td align="center" >0</td>
<td align="center" >11</td>
</tr>
<tr>
<td colspan="12" style="border-style:None;width:100%;">
<table style="width:100%" border="0" style="border-color:Black;border-width:1px;border-style:solid;width:100%;border-collapse:collapse;">
<tr>
<td></td>
<td>
<table style="width:100%" cellspacing="0" border="0" >
<tr >
<td ><span >Level 12</span></td>
<td > abc</td>
<td >0</td>
<td align="center" >0</td>
<td align="center" >12</td>
</tr>
<tr>
<td colspan="12" style="border-style:None;width:100%;">
<table style="width:100%" border="0" style="border-color:Black;border-width:1px;border-style:solid;width:100%;border-collapse:collapse;">
<tr>
<td>
<table style="width:100%" >
<tr>
<td ><span >Level 13</span></td>
<td > abc</td>
<td >0</td>
<td align="center" >0</td>
<td align="center" >13</td>
</tr>
<tr>
<td colspan="12" style="border-style:None;width:100%;">
<table style="width:100%" border="0" style="border-color:Black;border-width:1px;border-style:solid;width:100%;border-collapse:collapse;">
<tr>
<td>
<table style="border-color:Black;border-width:1px;border-style:solid;width:100%;border-collapse:collapse;">
<tr >
<td>Level 14</td>
<td> abc</td>
<td >0</td>
<td align="center" >0</td>
<td align="center" >14</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</div>
</body>
</html>
</code>
Check this in front page. in design view it shows level 14 but in preview it shows levels till 13
can any one suggest why?
Thanx in advance
|
|
|
|
|
Well,
due to the fact that i'm not fascinated on tables like others are, i can only give you some simple hints.
But before that, i want to ask, why are you still using nested tables? It isn't even a rumour anymore, that it produces more problems and a massive code-overhead and eats RAM-Ressources 'til the earth stands still. Okay, whatever; Should be your problem, but if there's a reason why, please note it.
1) Even in html 4 it is not allowed to use style-attributes in every table-element when using nested tables, because without a class-definition in a cascading style sheet the doubled definitions are differently interpreted. That is, because tables are organized as a list inside the interpreter, so the normal 'The same tag inside (with a style definition) overrides the parent tag, is not given.
2) The 'td'-tags/-Elements that are emepty are written like '<td ></td>'. That space in between the opening tag should be deleted. Why? Because there are many browsers especially Mozilla-based and the older Netscapes that produce blank childs/doubled text-nodes inside the Element-Hierarchy while parsing the site on load. The result is unpredictable, because even the same browser-installation (same version, setup-type, etc.) is making it's behaviour dependent on the machines power (RAM, CPU-TYPE,etc.) and especially, the core-services provided by the operating system.
So just clean up that table-tree of those spaces. Anytime, you are building a site. There should be no element that hasn't attributes in it having spaces!
3) Due to the talk, any helper might give advice based on looking up the code-result in front-page... I'm not one of those 'pro-anything-else-than-microsoft'-users, but to be true, though' i'm loving microsoft-products i never used frontpage. But what i can tell you, is that the Internet Explorer (any Version) got a problem with '100%' of width in the style-attribute of a table. This is because the styles that are pre-defined for tables use borders, column-spacing and margin-settings, that make it impossible to run a table at '100%' width without defining a stylesheet that cleans up those pre-definitions.
In some tasks it could help to set the body-Element and all-Elements to zero padding and margin.
So the resulting code should look like:
(somewhere inside the <head>...
<style type="text/css">
<!--
body{
margin:0px;
padding:0px;
width:100%;
overflow:auto;
}
*{
margin:0px;
padding:0px;
}
//-->
</style>
This is the absolute minimum set of style definitions you might have to use if you want to use tables (especially nested ones) and are ready to style up any element directly per style-attributes.
4) It is definately unnessecary to double the styles, means: use per style-definition given width- and border-values OR use the direct formatting per attribute. Why? Because any browser-type has another way of processing those values. As the Internet Explorer until Version 5.5 is first rendering the site using the direct attributes (e.g.: width="100%", border="0") and then processes the style-definitions in your head-area, then adding external stylesheets and then at least looks up if a style-attribute is present inside the Element, Other browsers do it the other way around.
5) I didn't looked it all up, but check if you gave all values for width and border-width, etc. a px after the number, because some browsers don't recognize these values as pixel values if not set, instead using pt (Point ...typographic measure).
6) If you're not giving a doctype and/or a namespace definition, any browser will parse the code as html 3/4, but there you got a problem, because those who are using html 3 or html 3 compatibility don't recognize the %-sign in the width-attribute. Even the newest IE's and Safari, Konqueror and Co. partly don't recognize them because of the downward-compatibility and different table-handling.
So at least you should give a doctype. Look up http://www.w3.org and search for doctype headers.
If you don't know what this is, here is an example for a XHTML 1 Transitional DocType:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
The DocType in any case has to be the first line(s) in your html-file if you want to use it.
The according namespace to this (used in newer browsers, capable of XML-presenting) is:
<html xmlns="http://www.w3.org/1999/xhtml">
So this one is used instead the typical '<html>'-Element.
Well, i really don't know if any of this might have had helped you if you're through with practicing it, but maybe?
Just try it, take your time.
If you got special questions you're free to send me an e-Mail. Please be specific and precisely as you're able if you're asking for help.
You know, code is poetry, fine and tasty; ...but taste sometimes isn't discussable.
You're Welcome,
Paeth.Claudius-Raphael
|
|
|
|
|
Hi,
Thanks for your reply. I am using Nested DataGrid in one of my page. and the output of that datagrid is nested tables when it renders the nested datagrid. I removed all the style from the table but still it is not showing me the 14th level. I noticed one more thing that if I remove top table i.e. root table then it shows me the 14th level. That means it just shows me 12 levels only. So, is their any limit for nested tables. I google this problem but i found that their is no limit for nesting the tables. Then why it shows only 12 nested table. I have given an example of frontpage for all to see the design view as well as preivew. In design view it's showing me all the levels but when I preview that page it shows levels till 13. I also see that output in browser (Internet Explorer).
When that perticular page is displayed to the user, user can see only 12 levels but in view source of that page their are more levels.
Is this is a limit of table or any drawback of html when it displays the output in browser?
Please suggest.
|
|
|
|
|
What should be the final view/look of that piece of structure?
Means: In which way you want to use it?
Which browser(s) and version(s) do you use (exactly) to look the results up?
Do you have the page online?
Is there a reason that binds you to realize the structure with nested-tables?
|
|
|
|
|
That page is not online now.
I am Using Internet Explorer 6.0 with service pack 1.
The sturcture is something like tree view. User can drill down to the Parent To Child. User can expand and collapse the records so I need to use the nested datagrid which finally render the nested table. The posted code is part of html output of that page. You can view that output if you want me to mail that html to you then i'll mail to you.
|
|
|
|
|
firefox doesn't use fireEvent.
and i want to fire an event when the value of the text changed, and when firing the event i should pass the key that has been press or the event it self?
Faris Madi
Nothing Comes Easy (N.C.E.)
|
|
|
|
|
I believe you use createEvent(...) and dispatchEvent(evObject)
led mike
|
|
|
|
|
Greetings all!
I'm quite new to javascript so i may have some rather silly kind of questions... but anyway here's the problem...
I want to loop through all the elements in a form so as to check their values in order to validate the relevant fields, i thought i could get the number of form objects within the form using "formName.length." Then use a loop to go through all the form fields.
It seems formName.length is not working for me ... it's returning "undefined" or "0" values. How could i get the number of form objects within a certain form.
My code is as follows:
[CODE]
window.moveTo(100,100);
window.resizeTo(300,460);
//window.locationbar.visible=false;
//window.menubar.visible=false;
//window.personalbar.visible=false;
//window.scrollbars.visible=false;
//window.statusbar.visible=false;
//window.toolbar.visible=false;
//window.resize=false;
//window.resizeable=no;
var elementNo;
elementNo = document.registrationForm.length;
//elementNo = document.registrationForm.txtFirstName.value;
var num;
num = document.forms[0].length;
var counter = 0;
var myMessage = "Please ensure that you have filled in the following fields:\n";
var myFieldsAlert = "";
var myAlertFlag="0";
function validate(){
//
alert("abc "+elementNo);
alert("abc "+num);
/**/
while(counter<elementNo){
//
if(registrationForm.elements[counter].value==""){
myFieldsAlert += "-"+registrationForm.elements[counter].id+"\n";
myAlertFlag="1";
}
if(registrationForm.optGenderM.value!="0" || registrationForm.optGenderF.value!="1"){
myFieldsAlert += "-Gender\n";
myAlertFlag="1";
}
counter++;
}
/**/
/**/
if(myAlertFlag=="1"){
alert(myMessaage+myFieldsAlert);
}
else{
registrationForm.submit();
}
myAlertFlag ="0";
/**/
return false;
}
[/CODE]
Could someone please enlighten me on the issue at hand and propose a solution. (By the way the code is in a HTML page which is called up as a popup).
Any help would be greatly appreciated...
|
|
|
|
|
Hi
I am using COM object in Web Application. There is a problem to solve authentication & authorization issue for Server site. At the time of using the COM object it shows the error " ACCESS DENIED ". If I am writing <identity impersonate="true"> in web.config, it is OK but the AJAX file is not accessible for that reason.
if I am using iisreset in Run command, then the whole application is OK, but it is not possible to reset iis again and again in production server. Have you any idea for this?
For more clarification, suppose there is a link in a Web page interface. After click the link, one Word document will open. How we solve authentication/authorization issue in iis without affecting to other files like AJAX.
I am using ASP.NET with C#. I am not using MTS.
any idea, please write.
regards
|
|
|
|