16,004,602 members
Sign in
Sign in
Email
Password
Forgot your password?
Sign in with
home
articles
Browse Topics
>
Latest Articles
Top Articles
Posting/Update Guidelines
Article Help Forum
Submit an article or tip
Import GitHub Project
Import your Blog
quick answers
Q&A
Ask a Question
View Unanswered Questions
View All Questions
View C# questions
View C++ questions
View Javascript questions
View Visual Basic questions
View .NET questions
discussions
forums
CodeProject.AI Server
All Message Boards...
Application Lifecycle
>
Running a Business
Sales / Marketing
Collaboration / Beta Testing
Work Issues
Design and Architecture
Artificial Intelligence
ASP.NET
JavaScript
Internet of Things
C / C++ / MFC
>
ATL / WTL / STL
Managed C++/CLI
C#
Free Tools
Objective-C and Swift
Database
Hardware & Devices
>
System Admin
Hosting and Servers
Java
Linux Programming
Python
.NET (Core and Framework)
Android
iOS
Mobile
WPF
Visual Basic
Web Development
Site Bugs / Suggestions
Spam and Abuse Watch
features
features
Competitions
News
The Insider Newsletter
The Daily Build Newsletter
Newsletter archive
Surveys
CodeProject Stuff
community
lounge
Who's Who
Most Valuable Professionals
The Lounge
The CodeProject Blog
Where I Am: Member Photos
The Insider News
The Weird & The Wonderful
help
?
What is 'CodeProject'?
General FAQ
Ask a Question
Bugs and Suggestions
Article Help Forum
About Us
Search within:
Articles
Quick Answers
Messages
Comments by S.Rajendran from Coimbatore (Top 200 by date)
S.Rajendran from Coimbatore
1-Aug-16 3:56am
View
I tried with the following. Not working. Even it not reaches the breakpoint at code.
<script type="text/javascript">
function progressiveTd() { Panel5.Visible = true;.....}
</script>
<td id="progressiveTd" onclick="progressiveTd_Click"..
in code:
protected void progressiveTd_Click(object sender, EventArgs e)
{
ScriptManager.RegisterClientScriptBlock(this, GetType(), "", "progressiveTd();", true);
}
S.Rajendran from Coimbatore
16-May-15 3:34am
View
As said by you earlier I tried with a NUMERIC type column and when I wanted to get it to variable I got error when the number in the column exceeds 6,2 (with decimal).
String[] columns = { helper.TX_UID, helper.TX_NAME, helper.TX_PARTICULARS, helper.TX_AMOUNT, helper.TX_DATE,helper.TX_CONTRA}; // from tx_table..tested ok
Cursor c = db.query(VivzHelper.TX_TABLE, columns, (helper.TX_ID + "='" + name + "' AND " + helper.TX_DATE + "= '" + td + "'"), null, null, null,null);
gt = 0;
gt_selectedItem_number = 0; // numbers refers to int variable for int column
if (c != null) {
c.moveToFirst();
while (c.isAfterLast() == false) {
String txTotal=null;
String v_uid=(c.getString(0));//tx_id is passed here..not used ofcourse
txTotal = (c.getString(3)); //not ok
Float fl=(c.getFloat(3)); //not ok
How to get , the NUMERIC coulumn TX_AMOUNT to pass to a suitable variable for calculation purposes?
S.Rajendran from Coimbatore
29-Mar-15 10:35am
View
Well what you said is correct. It should have been textView6.
S.Rajendran from Coimbatore
15-Mar-15 6:12am
View
No it is not going in the loop.
S.Rajendran from Coimbatore
15-Mar-15 5:13am
View
I did as you said. Not working. Same problem.
S.Rajendran from Coimbatore
10-Mar-15 7:04am
View
Thanks.It works.
S.Rajendran from Coimbatore
10-Mar-15 6:45am
View
Thanks it works. I have same type issue with drop table too.
private static final String DROP_TABLE= "DROP TABLE " +TABLE_NAME+" IF EXISTS";
S.Rajendran from Coimbatore
10-Mar-15 6:12am
View
I did like as you said ie. a blank in front of strings, but not helping:
private static final String CREATE_TABLE= " CREATE TABLE" +TABLE_NAME+ "
(" +UID+ " INTEGER PRIMARY KEY AUTOINCREMENT," +NAME+ " VARCHAR(255));";
S.Rajendran from Coimbatore
10-Mar-15 4:18am
View
In another new apps test project I get the same problem if use the line ' SQLiteDatabase db=vivzHelper.getWritableDatabase();' in MainActivity.java that runs with VivzHelper.java (where DB is created). If I dont use that line I dont get that error.
public class MainActivity extends ActionBarActivity {
VivzHelper vivzHelper;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
vivzHelper=new VivzHelper(this);
SQLiteDatabase db=vivzHelper.getWritableDatabase();
}
public class VivzHelper extends SQLiteOpenHelper{
private static final String DATABASE_NAME="vivzdatabase";
private static final String TABLE_NAME="VIVZTABLE";
private static final String DATABASE_VERSION="1";
private static final String UID="_id";
private static final String NAME="name";
private static final String PASSWORD="password";
private static final String CREATE_TABLE="CREATE TABLE="+TABLE_NAME+"("+UID+" INTEGER PRIMARY KEY AUTOINCREMENT ,"+NAME+" VARCHAR(255));";
private static final String DROP_TABLE="DROP TABLE"+TABLE_NAME+"IF EXIST";
private Context context;
public VivzHelper(Context context)
{
super(context,"",null,1);
this.context=context;
Message.message(context,"constructor called");
}
@Override
public void onCreate(SQLiteDatabase db) {
try {
db.execSQL(CREATE_TABLE);
Message.message(context,"on create called");
} catch (SQLException e) {
Message.message(context,""+e);
}
}
@Override
public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) {
try {
db.execSQL(DROP_TABLE);
Message.message(context,"on upgrade called");
onCreate(db);
} catch (SQLException e) {
Message.message(context,""+e);
}
}
S.Rajendran from Coimbatore
10-Mar-15 3:38am
View
i did like this. In ddms in loglevel I selected 'error'. Some message like 'applying filter' is appearing at the bottom and disappears immediately.
S.Rajendran from Coimbatore
10-Mar-15 2:49am
View
in ddms how to find dump error
S.Rajendran from Coimbatore
10-Mar-15 2:48am
View
After running the app the event log:
12:17:31 PM Gradle build finished in 8 sec
12:17:31 PM Session 'app1': running
S.Rajendran from Coimbatore
10-Mar-15 2:34am
View
is that event log?
S.Rajendran from Coimbatore
5-Feb-15 10:20am
View
he paths are diff. What is application screen/
S.Rajendran from Coimbatore
29-Jan-15 6:42am
View
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent" android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_margin"
android:paddingBottom="@dimen/activity_vertical_margin"
tools:context=".MainActivity"
S.Rajendran from Coimbatore
29-Jan-15 6:40am
View
<relativelayout xmlns:android="http://schemas.android.com/apk/res/android"
="" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="match_parent" android:paddingleft="@dimen/activity_horizontal_margin" android:paddingright="@dimen/activity_horizontal_margin" android:paddingtop="@dimen/activity_vertical_margin" android:paddingbottom="@dimen/activity_vertical_margin" tools:context=".MainActivity">
S.Rajendran from Coimbatore
29-Jan-15 6:39am
View
Deleted
My activity_main module:
<relativelayout xmlns:android="http://schemas.android.com/apk/res/android"
="" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="match_parent" android:paddingleft="@dimen/activity_horizontal_margin" android:paddingright="@dimen/activity_horizontal_margin" android:paddingtop="@dimen/activity_vertical_margin" android:paddingbottom="@dimen/activity_vertical_margin" tools:context=".MainActivity">
<Button
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="New Button"
android:id="@+id/button"
android:layout_alignParentRight="true"
android:layout_alignParentEnd="true" />
S.Rajendran from Coimbatore
29-Jan-15 6:26am
View
If I copy and paste the tags are missing for xml files and not complete. I copied this JAva code and pasted and it is OK. Like this for xml files it is not carried out exactly. How to do it to paste here?
S.Rajendran from Coimbatore
16-Jan-15 11:36am
View
The plain phone image through emulator is visible without text. After few seconds I get a dialogue box stating 'emulator-x86.exe has stopped working'
S.Rajendran from Coimbatore
16-Jan-15 11:27am
View
I did not receive your latest one. Can you resend it again.
S.Rajendran from Coimbatore
16-Jan-15 11:13am
View
In your reply to Peter there is only a single line.
S.Rajendran from Coimbatore
16-Jan-15 10:58am
View
I changed accordingly but not getting displayed.
<textview
android:id="@+id/main_textview"
="" android:text="@string/textview" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginleft="20dp" android:layout_margintop="20dp"
="">
S.Rajendran from Coimbatore
16-Jan-15 9:50am
View
activity_main.xml
S.Rajendran from Coimbatore
11-Jan-15 11:19am
View
Yes its where I attempted..no use
S.Rajendran from Coimbatore
6-Jan-15 9:50am
View
Thank You. It works.Fine.
S.Rajendran from Coimbatore
6-Jan-15 6:48am
View
Yes, but it is not even getting hidden.
S.Rajendran from Coimbatore
6-Jan-15 6:37am
View
<div class="menubar" style=" height:33px; border-style:groove; border-width:thin; width:859px;">
<ul>
<li>
Contact us
</li>
<li>
Causes list
</li>
<li>
Corporate issues
<ul style="">
<li>
Incorporation
</li>
<li>
Merger and acquisitions
</li>
<li>
Arbitration
</li>
<li>
Representations
</li>
<li>
Legal outsourcing
</li>
<li>
Intellectual property
</li>
</ul>
</li>
S.Rajendran from Coimbatore
21-Dec-14 6:36am
View
i tried like this not working:
imageBox1 ul li ul[id="smap"]:hover >.location1
S.Rajendran from Coimbatore
8-Dec-14 0:12am
View
Hey, it works now. Earlier I didnt notice a line break in the code that I copied from yours. Thanks.
S.Rajendran from Coimbatore
8-Dec-14 0:07am
View
the jquery is actually before the script but no effect.
<script type="text/javascript" src="http://code.jquery.com/jquery-1.11.1.min.js"></script>
<script type="text/javascript">
S.Rajendran from Coimbatore
8-Dec-14 0:06am
View
I tried with your code but the same state is maintained..only the 1st image is static.
S.Rajendran from Coimbatore
8-Dec-14 0:05am
View
The jquery include line is well before the script block, like this..but not working
<script type="text/javascript" src="http://code.jquery.com/jquery-1.11.1.min.js"></script>
<script type="text/javascript">
S.Rajendran from Coimbatore
7-Dec-14 11:16am
View
I tried but not working.
S.Rajendran from Coimbatore
7-Dec-14 6:18am
View
Yes, latestly after submitting the code I also included the Jquery and tried like:
<script src="//ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>
S.Rajendran from Coimbatore
7-Dec-14 6:07am
View
I checked with the sample. everything is OK.
My browser being chrome I used 'ctrl+shift+i' for debugger.
I find no difference. The first image as it is is only getting displayed.
S.Rajendran from Coimbatore
7-Dec-14 5:53am
View
Only the first 'show' image is shown and the other two are not appearing after hiding the previous image. It seems javascript is not getting activated.
S.Rajendran from Coimbatore
7-Dec-14 2:41am
View
Well, it works. The mistake was that I have a space between 'About' and 'us' in class
instead of coding as 'Aboutus' as a single word without space. Thanks.
#header #nav .Aboutus
{
border:1px solid blue;
}
Now, how to use margin-left for the same class 'Aboutus'.
S.Rajendran from Coimbatore
7-Dec-14 2:26am
View
No, it is not working.
S.Rajendran from Coimbatore
2-Dec-14 0:49am
View
My table is within a repeater and I have not put it in asp tag; it is in html tag.
S.Rajendran from Coimbatore
21-Nov-14 8:58am
View
Now when I changed position:inherit it works fine but it is not appearing within the 'header' div. It is appearing outside that 'header' div. My header div code as follows:
#header {
top:0px;
margin:0px;
padding:0px;
background-color:Gray;
color:white;
height:51px;
position :fixed;
text-align:left;
padding:5px;
width:1012px;
}
#header h1
{
margin-top:-2px;
color:Yellow;
font-size:xx-large;
}
S.Rajendran from Coimbatore
20-Nov-14 9:51am
View
???
S.Rajendran from Coimbatore
17-Nov-14 1:58am
View
The behavior of the scroll bar moving upwards after show button clicked makes the user to pull down the scroll bar to view the selected image that resulted through 'Showbutton_Click' event in c#. So, if this scroll bar behavior of moving upwards is prevented, the user will be happy to see his selected image.
S.Rajendran from Coimbatore
16-Nov-14 9:39am
View
I never thought scrolling up is wrong,your highness.
S.Rajendran from Coimbatore
16-Nov-14 9:37am
View
Deleted
No.
S.Rajendran from Coimbatore
16-Nov-14 9:37am
View
Deleted
no.
S.Rajendran from Coimbatore
14-Nov-14 10:41am
View
helpless!!
S.Rajendran from Coimbatore
14-Nov-14 0:02am
View
I tried with args.set_cancel(true); ..is not helping
S.Rajendran from Coimbatore
13-Nov-14 4:51am
View
Thanks. It works. The updateprogress works as well as with first click submission also works. But the updateprogress works for all events within the same page instead of only for that last 'submit' button.
S.Rajendran from Coimbatore
13-Nov-14 3:39am
View
I tried with your code but the first click itself is disabled. I need first click to be effected and further clicks should be disabled.
S.Rajendran from Coimbatore
13-Nov-14 3:38am
View
Deleted
I tried with your code but the first click itself is disabled. I need first click to be effected and further clicks should be disabled.
S.Rajendran from Coimbatore
13-Nov-14 1:14am
View
Yes I have. As said earlier, the click event is not getting triggered on first click but gets triggered after 2nd click and my purposed is solved. If I remove the 'update progress' it gets triggered on first click itself.
S.Rajendran from Coimbatore
13-Nov-14 0:54am
View
Even it is kept under 'head' not working.
S.Rajendran from Coimbatore
12-Nov-14 23:43pm
View
No. If I comment the UpdateProgress it works on 1st click.
S.Rajendran from Coimbatore
12-Nov-14 22:46pm
View
If I comment the UpdateProgress it works on first click. If not commented I have to
click twice.
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<contenttemplate>
<asp:Label ID="Label99" runat="server" Width="145px">
<Triggers>
<asp:AsyncPostBackTrigger ControlID="Button4" />
</Triggers>
<script language="javascript" type="text/javascript">
var prm = Sys.WebForms.PageRequestManager.getInstance();
prm.add_initializeRequest(InitializeRequest);
prm.add_endRequest(EndRequest);
var postBackElement;
function InitializeRequest(sender, args) {
if (prm.get_isInAsyncPostBack())
args.set_cancel(true);
postBackElement = args.get_postBackElement();
if (postBackElement.id == 'Button4')
$get('UpdateProgress1').style.display = 'block';
}
function EndRequest(sender, args) {
if (postBackElement.id == 'Button4')
$get('UpdateProgress1').style.display = 'none';
}
</script>
<asp:UpdateProgress ID="UpdateProgress1" DynamicLayout=true AssociatedUpdatePanelID="UpdatePanel1" runat="server" >
<ProgressTemplate>
<table cellspacing="1" runat="server" id="table76" style=" margin-left:720px; margin-top:1360px; position:absolute;">
<tr>
<td>
<asp:Image ID="Image21" runat="server" DescriptionUrl="~/images/updateprogress.gif"
Height="60px" ImageUrl="~/images/updateprogress.gif" Width="20px" BackColor="White"/>
</td>
</tr>
</table>
</ProgressTemplate>
S.Rajendran from Coimbatore
12-Nov-14 11:07am
View
UseSubmitBehavior is not helping..
S.Rajendran from Coimbatore
12-Nov-14 10:39am
View
If I put a breakpoint at pageload it goes to button4_event. If I put breakpoint direct at button_event it is not holding! One more thing..I have a Update progress and if I comment it, the button4 works fine with 1st click.. hereunder my Update progress code:
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<contenttemplate>
<asp:Label ID="Label99" runat="server" Width="145px">
<Triggers>
<asp:AsyncPostBackTrigger ControlID="Button4" EventName="Click"/>
</Triggers>
<asp:UpdateProgress ID="UpdateProgress1" DynamicLayout=true AssociatedUpdatePanelID="UpdatePanel1" runat="server" >
<ProgressTemplate>
<table cellspacing="1" runat="server" id="table76" style=" margin-left:720px; margin-top:1360px; position:absolute;">
<tr>
<td>
<asp:Image ID="Image21" runat="server" DescriptionUrl="~/images/updateprogress.gif"
Height="60px" ImageUrl="~/images/updateprogress.gif" Width="20px" BackColor="White"/>
</td>
</tr>
</table>
</ProgressTemplate>
S.Rajendran from Coimbatore
12-Nov-14 9:48am
View
There is nothing like clean solution under build
S.Rajendran from Coimbatore
12-Nov-14 9:45am
View
If validation is run for 1st time and then while proceeding with rectified 'submit' btn things are OK!
S.Rajendran from Coimbatore
12-Nov-14 9:34am
View
If validation is run for 1st time and then while proceeding with rectified 'submit' btn things are OK!
S.Rajendran from Coimbatore
12-Nov-14 9:25am
View
how to clean solution?
S.Rajendran from Coimbatore
12-Nov-14 9:24am
View
its not working.
S.Rajendran from Coimbatore
8-Nov-14 11:09am
View
.tooltip
{
display: inline;
position: relative;
text-decoration: none;
top: 0px;
left: 4px;
border-style:none;
}
.tooltip:hover:after
{
background: #333;
background: rgba(0,0,0,.8);
border-radius: 5px;
top: -5px;
color: #fff;
content: attr(alt);
left: 160px;
padding: 5px 15px;
position: absolute;
z-index: 98;
width: 150px;
background-color:Red;
}
.tooltip:hover:before
{
border: solid;
border-color: transparent black;
border-width: 6px 6px 6px 0;
bottom: 20px;
content: "";
left: 155px;
position: absolute;
z-index: 99;
top: 3px;
}
S.Rajendran from Coimbatore
8-Nov-14 10:34am
View
I used like this and works with event triggering but 'tooltip' class is not functioning.
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<contenttemplate>
<asp:HyperLink ID="HyperLink1" runat="server" Class="tooltip" NavigateUrl="#" Text="" />
<asp:Button ID="Button6" runat="server" Text='Famous short eats' class="tooltip" causesvalidation="false" OnClick="btnprasiddhishorteats_click" />
S.Rajendran from Coimbatore
4-Nov-14 1:25am
View
<asp:UpdatePanel ID="dd" runat="server">
<contenttemplate>
<div>
<asp:Panel ID="Panel2" runat="server" Width="158" Height="200" BackColor=ControlLightLight BorderWidth=".4" BorderStyle="Groove" BorderColor="White"
style=" margin-top:160px; margin-left:265px; border-bottom-style:groove; border-bottom-color:GrayText;
border-top-style:groove; border-top-color:Gray; border-top-width:medium; border-bottom-width:thick ">
<asp:Label ID="Label7" runat="server" Text="Category" ForeColor="Black" BackColor="ControlLightLight" style=" font-family:Verdana; font-weight:bolder; position:absolute; margin-left:35px; margin-top:16px; font-size:small ">
<br />
<%--<asp:Button ID="Button5" runat="server" Text='Herbal-Internal' Class="stylebutton" Font-Size="Small" BackColor="ControlLightLight" CausesValidation="false" OnClick="btnherbal_click" ForeColor="#666666" Style=" cursor:pointer; font-family:Verdana; font-weight:normal; margin-top:28px; margin-left:0px; " BorderStyle="None" />--%>
<asp:button id="Button5" runat="server" text="Herbal-Internal" class="stylebutton" causesvalidation="false" onclick="btnherbal_click" style=" margin-top:28px" />
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<contenttemplate>
<asp:Button ID="Button6" runat="server" Text='Famous short eats' class="stylebutton" causesvalidation="false" OnClick="btnprasiddhishorteats_click" />
S.Rajendran from Coimbatore
25-Oct-14 6:49am
View
How to position the img at required location in the page dynamically in C#?
S.Rajendran from Coimbatore
7-Jul-14 5:56am
View
I dont want the color of the whole thing to be in red. I want only the text inside that variable 'v_totalitemsfound' to be in red.
S.Rajendran from Coimbatore
7-Jul-14 3:28am
View
This is for web form in asp.net
S.Rajendran from Coimbatore
19-Jun-14 23:53pm
View
I am in project A and I want to call the form Default.aspx from project B in same directory.
S.Rajendran from Coimbatore
19-Jun-14 6:34am
View
i want to submit to this form
S.Rajendran from Coimbatore
10-Jun-14 2:20am
View
In fact, I want to get those rows that has values greater than or equal to 6 in column 'SeasonFromMonthNumber' and less than or equal to 6 in column name 'SeasonToMonthNumber'.
S.Rajendran from Coimbatore
10-Jun-14 2:12am
View
I want the query to show the value in the column 'season' which is 'jul-dec'. But my above query shows just the column name 'season' without the value contained in it, that is 'jul-season'.
S.Rajendran from Coimbatore
5-Jun-14 22:44pm
View
in debug I could see label11 is assigned with 'Check season'
S.Rajendran from Coimbatore
18-May-14 7:31am
View
Oh fine. Thanks.
S.Rajendran from Coimbatore
18-May-14 0:57am
View
string filePath = Path.Combine(Application.StartupPath, "/WindowsFormsToSqlTest/WindowsFormsToSqlTest/CrystalReport11.rpt");
reportDocument.Load(filePath);
crystalReportViewer1.ReportSource = reportDocument;
Note:
If I change the file as CrystalReport10.rpt and wanted to see its contents it shows the same details of CrystalReports11.rpt.
S.Rajendran from Coimbatore
18-May-14 0:55am
View
It works. Earlier I did not include the project name. Well. Thank you.
AT the same time if I wanted to show the report from another file say 'CrystalReport10.rpt' the result is that it shows the same report of 'CrystalReport11.rpt"!. Ofcourse in the path I have mentioned the file name as 'CrystalReport10.rpt'. Why is it so?
The code:
string filePath = Path.Combine(Application.StartupPath, "/WindowsFormsToSqlTest/WindowsFormsToSqlTest/CrystalReport10.rpt");
reportDocument.Load(filePath);
crystalReportViewer1.ReportSource = reportDocument;
S.Rajendran from Coimbatore
17-May-14 7:23am
View
I tried.Same error comes.
S.Rajendran from Coimbatore
17-May-14 6:51am
View
i dont see the answer!!
S.Rajendran from Coimbatore
17-May-14 5:46am
View
it is sql table and used 'crystalreportviewer' to design the report
S.Rajendran from Coimbatore
12-May-14 6:23am
View
I made a mistake by commenting InitializeComponent();
Now it works . Thank you.
S.Rajendran from Coimbatore
12-May-14 6:15am
View
Yes, capital simple etc all are correct.
S.Rajendran from Coimbatore
12-May-14 6:08am
View
Yes, it is available in that path.
S.Rajendran from Coimbatore
12-May-14 5:59am
View
The value in filePath shows like this:
"C:\\WindowsFormsToSqlTest\\WindowsFormsToSqlTest\\bin\\Debug\\CrystalReport120514test.rpt"
S.Rajendran from Coimbatore
12-May-14 5:57am
View
After copying how to go and check the file exist or not
S.Rajendran from Coimbatore
12-May-14 5:45am
View
I tried both 'copy always' and copy if newer'.
For both I get exception at line 'crystalReportViewer1.ReportSource = reportDocument; '
as 'object reference not set to an instance of an object'.
S.Rajendran from Coimbatore
12-May-14 5:27am
View
The file 'CrystalReport120514test.rpt' is in solution explorer.
I tried with the follwoing:
public dynamicreporttest()
{
ReportDocument reportDocument = new ReportDocument();
string filePath = Path.Combine(Application.StartupPath, "CrystalReport120514test.rpt");
reportDocument.Load(filePath);
crystalReportViewer1.ReportSource = reportDocument;
}
private void dynamicreporttest_Load(object sender, EventArgs e)
{
// this.crystalReportViewer1.RefreshReport();
}
I get the an exception at line 'reportDocument.Load(filePath); stating 'load report failed'
S.Rajendran from Coimbatore
9-May-14 10:03am
View
Earlier I didnt mention that I have master page. Anyhow you gave me a good clue and that I applied in my master page. The exception problem is solved. Thanks.
if (Session["FirstSessionTag"] != null)
{
string myVal = Session["FirstSessionTag"].ToString();
}
else
{
Session["FirstSessionTag"] = "*";
Response.Redirect("Default.aspx");
}
S.Rajendran from Coimbatore
9-May-14 7:14am
View
I dont get you. What is that :D
S.Rajendran from Coimbatore
9-May-14 7:10am
View
Can you please tell me how to go that update section. I am not familiar with this.
S.Rajendran from Coimbatore
9-May-14 7:06am
View
2008
S.Rajendran from Coimbatore
9-May-14 7:02am
View
I cant find IIS mangager in my administrative tools.
S.Rajendran from Coimbatore
9-May-14 6:55am
View
how to restart the IIS server
S.Rajendran from Coimbatore
7-May-14 7:13am
View
The mistake lies at line:
photos[i] = new AjaxControlToolkit.Slide("ImagesViewAndEditCartAspxTopLeftEndSlideShow/" + file[file.Length - 1],
I tested in local host. If I remove that '/' , the same imageless sliding with 'undefined' word is hapenning.
S.Rajendran from Coimbatore
7-May-14 6:47am
View
The mistake lies at line:
photos[i] = new AjaxControlToolkit.Slide("ImagesViewAndEditCartAspxTopLeftEndSlideShow/" + file[file.Length - 1],
I tested in local host. If I remove that '/' , the same imageless sliding with 'undefined' word is hapenning.
S.Rajendran from Coimbatore
7-May-14 4:51am
View
In deployment folder everything is ok.
S.Rajendran from Coimbatore
7-May-14 3:28am
View
In remote, the slider functions but the image is not appearing. Just the slider moves with a word 'undefined' for each image. All the corresponding image files are well in the root, I have checked it thoroughly. Ajaxcontrol .dll is also there. Hereunder I submit the code of one of the 'slideshow.cs' file under the folder App_Code. It runs well in localhost.
using System;
using System.Collections;
using System.Linq;
using System.Web;
using System.Web.Services;
using System.Web.Services.Protocols;
using System.Xml.Linq;
///
/// Summary description for Slideshow
///
[WebService(Namespace = "http://tempuri.org/")]
[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
// To allow this Web Service to be called from script, using ASP.NET AJAX, uncomment the following line.
[System.Web.Script.Services.ScriptService]
public class Slideshow : System.Web.Services.WebService {
public Slideshow () {
//Uncomment the following line if using designed components
//InitializeComponent();
}
//[WebMethod]
[System.Web.Services.WebMethod]
[System.Web.Script.Services.ScriptMethod]
public AjaxControlToolkit.Slide[] GetSlides()
{
string[] imagenames = System.IO.Directory.GetFiles(Server.MapPath("~/ImagesViewAndEditCartAspxTopLeftEndSlideShow"));
AjaxControlToolkit.Slide[] photos = new AjaxControlToolkit.Slide[imagenames.Length];
for (int i = 0; i < imagenames.Length; i++)
{
string[] file = imagenames[i].Split('\\');
photos[i] = new AjaxControlToolkit.Slide("ImagesViewAndEditCartAspxTopLeftEndSlideShow/" + file[file.Length - 1], file[file.Length - 1], "");
}
return photos;
}
}
S.Rajendran from Coimbatore
7-May-14 1:04am
View
Another file named as App_code.compiled is also available
S.Rajendran from Coimbatore
7-May-14 1:01am
View
Yes fine I could see it as App_code.dll
S.Rajendran from Coimbatore
7-May-14 0:55am
View
Ofcourse, xxx.aspx.cs files are getting compiled as dll but xxx.cs files are not even getting published and could be seen in the published folder. These xxx.cs files are inside a folder named as App_Code in solution explorer and this folder also cant be seen in that publised file.
S.Rajendran from Coimbatore
7-May-14 0:43am
View
Before publishing I tested in local host and it worked well.
S.Rajendran from Coimbatore
6-May-14 23:33pm
View
It is website.
S.Rajendran from Coimbatore
4-May-14 10:45am
View
What you said is correct . Thank you.
S.Rajendran from Coimbatore
4-May-14 7:47am
View
Should I use this virtual directory in IIS to upload files to remote. Anyhow, how to publish the website into this virtual directory in IIS. Normal publishing I am able to do it. Anything to do with Publish Website dialog box?
S.Rajendran from Coimbatore
4-May-14 5:49am
View
I did like this in my master page:
<head runat="server">
<title>Mytitle</title>
- no effect
S.Rajendran from Coimbatore
3-May-14 5:51am
View
My project comprises of master pages and content pages. I did it using asp.net c#.
When I run the project, the layout is well centred and itact and the appearance is fine.
When run FF or IE the look of the layout gets altered .
S.Rajendran from Coimbatore
3-May-14 4:19am
View
I am using asp.net where it is not working.
S.Rajendran from Coimbatore
28-Apr-14 10:54am
View
How to for word format?
S.Rajendran from Coimbatore
25-Apr-14 10:51am
View
I tried:
protected override void OnPreRender(EventArgs e)
{
//((Table)Master.FindControl("tgg")).Visible = false;
//base.OnPreRender(e);
HtmlTable dt = Master.FindControl("tgg");
dt.Visible = false;
}
error; ARe you missing a cast? is appearing!
S.Rajendran from Coimbatore
23-Apr-14 7:46am
View
Now when I used $("#Table3").on('mouseover', function() {.. only the first table of the datalist
works when the mouse is over. When I move the mouse to second table , it is not working. However when moved to 2nd table , mouseleave function works.
S.Rajendran from Coimbatore
23-Apr-14 7:19am
View
I used $(":contains('Table3')").on('mouseover', function() {..
No error comes but when the mouse arrow is inside the form, the comments in div id "HI" is
flashing. When I take the mouse out of the form, the falshing and display of comments coming out of div id "HI" is stopped. Actually it has happen only when the arrow is on the Table3.
S.Rajendran from Coimbatore
23-Apr-14 7:13am
View
I tried with yours but get the same error like "Table3 does not exist in the current context is appearing."
S.Rajendran from Coimbatore
22-Apr-14 12:49pm
View
Well, I changed like that and also I had to do like: $('#<%=Image4.ClientID %>')
It worked after that.Thank you.
S.Rajendran from Coimbatore
22-Apr-14 6:55am
View
I replaced the first line. Not working. The page is a 'content' page.
S.Rajendran from Coimbatore
22-Apr-14 6:25am
View
I altered my code with the following 2 lines as shown by you. Its not working whereas. The 1st line is underlined in green. I am poor in jquery and javasript.
<script src="Scripts/jquery-1.4.3.min.js"></script>
<script type="text/javascript">
S.Rajendran from Coimbatore
13-Apr-14 9:56am
View
Even I keep the Label control outside Update Panel it is not working
S.Rajendran from Coimbatore
13-Apr-14 9:51am
View
No, I have not used it.
S.Rajendran from Coimbatore
12-Apr-14 11:50am
View
Well everything is hapenning but my requirement as said earlier is to paste in a folder of desktop.
S.Rajendran from Coimbatore
12-Apr-14 11:25am
View
Well..I tried it is not helping
S.Rajendran from Coimbatore
12-Apr-14 11:25am
View
I have saved the picture in 'paint' and when I tried to copy it is not allowing to copy!
S.Rajendran from Coimbatore
12-Apr-14 10:50am
View
No, it is not allowing to paste
S.Rajendran from Coimbatore
12-Apr-14 10:47am
View
There is no code, it is all manually done.
S.Rajendran from Coimbatore
12-Apr-14 10:43am
View
I tried as you said, and the image allowed me to copy in 'paint' and when I wanted to paste in desktop it is not hapenning!!
S.Rajendran from Coimbatore
12-Apr-14 6:54am
View
ctrl+v when used is copying in word but in desktop, i have a folder xx and I want it to be pasted there and that is not hapenning.
S.Rajendran from Coimbatore
1-Apr-14 1:00am
View
In property-event window I checked. Everything is OK. That is, TB1 has been assigned with TB1_Validated and TB2 with TB2 validated event respectively.
S.Rajendran from Coimbatore
1-Apr-14 0:44am
View
When I place the cursor on TB2 after form load why the event for TB1 is getting triggered?
It should not go to that event know?
S.Rajendran from Coimbatore
31-Mar-14 3:00am
View
This code worked for me.
if((dataGridView1.SelectedCells.Count ==1) && !validator.IsMatch(dataGridView1.Text))
Thank you.
S.Rajendran from Coimbatore
31-Mar-14 2:48am
View
Your updated code also not helping. The same problem as told previously.
S.Rajendran from Coimbatore
31-Mar-14 2:45am
View
This datagridview1 is generated from a table. The dgv has 6 headers and the first header is 'order no' . I use the data under this 'order no' of any row selected as per user's wish.
S.Rajendran from Coimbatore
31-Mar-14 2:23am
View
Now, what happens is that even if I dont select any rows, it escapes and not showing error. In short, if I select or dont select it is not validating.
S.Rajendran from Coimbatore
31-Mar-14 1:56am
View
I intend to select the first cell of any row as per choice.
S.Rajendran from Coimbatore
31-Mar-14 1:40am
View
I tried with your validation condition but still is not escaping.
S.Rajendran from Coimbatore
30-Mar-14 5:34am
View
v_orderno is a static int variable.
S.Rajendran from Coimbatore
27-Mar-14 7:23am
View
Is DBNull for dataset or datatable?
S.Rajendran from Coimbatore
27-Mar-14 7:11am
View
If it is null I want to assign v_shhipingcharges=0. This is not happenning. It is not that I want to convert null to int.
S.Rajendran from Coimbatore
24-Mar-14 10:35am
View
is there any reference like System.Web.UI.Controls in Add Reference list of solution explorer.
I could not find one like that.
S.Rajendran from Coimbatore
23-Mar-14 8:09am
View
The step by step tutorial is good.
S.Rajendran from Coimbatore
21-Mar-14 5:06am
View
I changed like <%# ID %> but no effect. The Jquery itself is not working. The first two controls to be hidden is displaying whereas in previous one it worked well.
S.Rajendran from Coimbatore
20-Mar-14 7:53am
View
While this code works with a separate page it is not in master page of my project. JQuery has no effect in master page. Panel1 displays on page load and mouseover mouseout has no effect. Please tell how to solve this.
S.Rajendran from Coimbatore
20-Mar-14 5:05am
View
Thank you.
S.Rajendran from Coimbatore
20-Mar-14 4:38am
View
On page load the panel1 is visible which I dont want. Only when mouseover the button I want the Panel1 to visble. How to make it?
S.Rajendran from Coimbatore
20-Mar-14 4:18am
View
Thank you.
S.Rajendran from Coimbatore
20-Mar-14 3:51am
View
$('#<%=Button1.ClientID %>').mouseover(function() {
$('.Panel1').hide();
});
$('#<%=Button1.ClientID %>').mouseout(function() {
$('.Panel1').show();
not working
S.Rajendran from Coimbatore
20-Mar-14 3:44am
View
I tried like this:
$('#Button1').mouseover(function() {
$('.Panel1').hide();
});
$('#Button1').mouseout(function() {
$('.Panel1').show();
not working.
S.Rajendran from Coimbatore
19-Mar-14 6:42am
View
This worked for me: "[a-z 0-9 \s \d-_ ()]{1,50}" Thank you all.
S.Rajendran from Coimbatore
19-Mar-14 3:18am
View
I used like this : ValidationExpression= "[^a-zA-Z0-9\s][d\-_][(][)]" not working
S.Rajendran from Coimbatore
18-Mar-14 5:34am
View
I used textbox to come out of the problem.
S.Rajendran from Coimbatore
18-Mar-14 4:47am
View
No.Not working.
S.Rajendran from Coimbatore
18-Mar-14 4:07am
View
Please ignore this submission
S.Rajendran from Coimbatore
14-Mar-14 11:11am
View
This link is VB but I am in C#
S.Rajendran from Coimbatore
13-Mar-14 9:51am
View
Fine. Thanks. It works.
S.Rajendran from Coimbatore
12-Mar-14 10:53am
View
not working
S.Rajendran from Coimbatore
12-Mar-14 10:52am
View
not working
S.Rajendran from Coimbatore
28-Feb-14 11:23am
View
is it a bug..no one is answering!!
S.Rajendran from Coimbatore
28-Feb-14 4:19am
View
Thanks. It helped me.
S.Rajendran from Coimbatore
28-Feb-14 3:53am
View
this is a content page
S.Rajendran from Coimbatore
27-Feb-14 10:53am
View
Not working..
S.Rajendran from Coimbatore
27-Feb-14 10:53am
View
EventName="Click" is not working.
behaviourId="popup" is also not working!
S.Rajendran from Coimbatore
27-Feb-14 10:47am
View
Always is not working
S.Rajendran from Coimbatore
26-Feb-14 23:24pm
View
Ofcourse everything is Ok but doesnt run in 'content page' as like in separate page. That's the problem for me right from beginning.
S.Rajendran from Coimbatore
26-Feb-14 21:58pm
View
The same code works when it is in a separate page. This same code does not work when it is in
content page with a master page. Can you please tell me where exactly is that unclosed tags.
S.Rajendran from Coimbatore
26-Feb-14 10:21am
View
I have already tried this , movingthis JS code into 'Head' and it did not work.
S.Rajendran from Coimbatore
26-Feb-14 9:48am
View
Deleted
Sorry, it is not helping.
S.Rajendran from Coimbatore
21-Feb-14 4:37am
View
Thank you. It works.
S.Rajendran from Coimbatore
20-Feb-14 11:00am
View
Thanks.It works.
S.Rajendran from Coimbatore
20-Feb-14 10:35am
View
I am poor in Js. Can you guide me how to use the full code for this.
S.Rajendran from Coimbatore
20-Feb-14 5:54am
View
v_stockavailability' should be changed to 'v_balancestock'
S.Rajendran from Coimbatore
20-Feb-14 4:53am
View
I changed <asp:asyncpostbacktrigger controlid="Button5" eventname="click" />, no use.
S.Rajendran from Coimbatore
20-Feb-14 3:56am
View
For the button I tried like this but get an exception like:
'could not find an event named 'btnherbal_click' on associated control 'Button5' for the trigger in UpdatePanel'dd'.'
<asp:UpdatePanel ID="dd" runat="server" UpdateMode="Conditional">
<triggers>
<asp:asyncpostbacktrigger controlid="Button5" eventname="btnherbal_click" />
</triggers>
<contenttemplate>
<asp:Button ID="Button5" runat="server" Text='Herbals ' Font-Size="Small" BackColor="AliceBlue" CausesValidation="false" OnClick="btnherbal_click" ForeColor="Black" Style=" cursor:pointer; font-family:Arial Black; font-weight:500; margin-top:28px " BorderStyle="None" />
S.Rajendran from Coimbatore
20-Feb-14 3:51am
View
Deleted
For the button I tried like this but get an exception like:
'Could not find an event named 'btnherbal_click' on associated control 'Button5' for the trigger in UpdatePanel 'dd'.'
<asp:UpdatePanel ID="dd" runat="server" UpdateMode="Conditional">
<triggers>
<asp:asyncpostbacktrigger controlid="Button5" eventname="btnherbal_click" />
</triggers>
<triggers>
<asp:asyncpostbacktrigger controlid="Button5" eventname="btnherbal_click" />
</triggers>
<contenttemplate>
<asp:Button ID="Button5" runat="server" Text='Herbals ' Font-Size="Small" BackColor="AliceBlue" CausesValidation="false" OnClick="btnherbal_click" ForeColor="Black" Style=" cursor:pointer; font-family:Arial Black; font-weight:500; margin-top:28px " BorderStyle="None" />
S.Rajendran from Coimbatore
20-Feb-14 3:17am
View
Thanks, it works.
S.Rajendran from Coimbatore
19-Feb-14 22:27pm
View
Yeah i changed and tried. Same problem exists.
S.Rajendran from Coimbatore
19-Feb-14 11:45am
View
I also tried like this but no use:
<iframe src="~/good food logo.jpg" runat="server" ></iframe>
S.Rajendran from Coimbatore
19-Feb-14 11:12am
View
Actually there is no error..but instead of that image "~foog food logo.jpg" , i get a different display like 'Server error in 'website1'/application ..the resource cannot be..' at that position. That' all.
S.Rajendran from Coimbatore
18-Feb-14 11:32am
View
I put breakpoint. It enters 'if(e.CommandName=Myevent..) and also crosses ChkButton.Enabled=true;', but enabled true is not happenning.
S.Rajendran from Coimbatore
17-Feb-14 11:44am
View
Its not working if put inside postback
S.Rajendran from Coimbatore
17-Feb-14 11:27am
View
If I use :
Button CheckOutBtn = (Button)DataList1.Controls[DataList1.Controls.Count - 1].FindControl("BtnCheckOut");
CheckOutBtn.Enabled = true;
i get no error but the 'BtnCheckOut' is not getting enabled.
S.Rajendran from Coimbatore
17-Feb-14 11:22am
View
When I use your code, I get error at line 'dd.FindControl' stating that 'cannot use local variable before it is declared'
S.Rajendran from Coimbatore
17-Feb-14 0:35am
View
I use the 'AddToCart' button.
The following is code behind;
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
DataTable tb = new DataTable();
tb = (DataTable)Session["ss"];
ViewState["CurrentTable"] = tb;
List<string> adds9 = new List<string>();
SqlDataAdapter da9 = new SqlDataAdapter("select ProductName,PicturePath from product", con);
SqlCommandBuilder cb9 = new SqlCommandBuilder(da9);
DataSet ds9 = new DataSet("product");
da9.Fill(ds9, "product");
DataList1.DataSource = ds9;
DataList1.DataBind();
DataList1.Visible = true;
}
}
public void dl_item_command(Object sender, DataListCommandEventArgs e)
{
if (e.CommandName == "myevent") // check commandname here
{
int index = e.Item.ItemIndex;
Button dd = (Button)DataList1.Items[index].FindControl("AddToCart");
dd.Text = "Added to cart";
DataTable dt = (DataTable)ViewState["CurrentTable"];
Session["ss"] = dt;
}
}
S.Rajendran from Coimbatore
12-Feb-14 6:44am
View
it is already in div tag. What is that min height and width.
S.Rajendran from Coimbatore
11-Feb-14 3:20am
View
Now though that problem is OK because of 'Readonly=true' I get a new problem because of it. That is after I select the date it is not getting stored in that TB. The date blinks and disappears.
I use a breakpoint at Textbox6_textchanged but it does not enter that breakpoint also.
S.Rajendran from Coimbatore
11-Feb-14 2:51am
View
Thanks.
S.Rajendran from Coimbatore
8-Feb-14 4:21am
View
Thanks. It works.
S.Rajendran from Coimbatore
8-Feb-14 3:49am
View
in the datatable 'dttxfile' the 3 rows are perfect and looks like.
341
341
341
S.Rajendran from Coimbatore
8-Feb-14 3:46am
View
SqlDataAdapter da2 = new SqlDataAdapter("select Carttxno from txfile where carttxno='" + v_carttxno + "'", sqlCon);
It works but the excel file has the column name 'Carttxno' of the table in all the 3 rows instead of values of the column 'carttxno'.
In my table 'txfile' I have 3 rows with values '341' in all the 3 rows. As per the code the excel file looks like this:
carttxno
carttxno
carttxno
341
Whereas it should look like:
341
341
341
S.Rajendran from Coimbatore
8-Feb-14 2:31am
View
Thanks.It worked.
S.Rajendran from Coimbatore
8-Feb-14 0:29am
View
I altered accordingly but it throws an exception for this new file:
Microsoft Office Excel cannot access the file 'C:\Users\RAJENDRAN\Desktop\clientstatement2/8/2014.xls'. There are several possible reasons:
• The file name or path does not exist.
• The file is being used by another program.
• The workbook you are trying to save has the same name as a currently open workbook.
S.Rajendran from Coimbatore
5-Feb-14 4:52am
View
Thanks. It works.
S.Rajendran from Coimbatore
5-Feb-14 3:27am
View
I changed the 3rd line like 'var fileInfo=new FileInfo(..). Still get the same error.
S.Rajendran from Coimbatore
24-Jan-14 23:31pm
View
Thanks.I got it with the following code:
// Cleanup
GC.Collect();
GC.WaitForPendingFinalizers();
ExcelApp.Quit();
Marshal.FinalReleaseComObject(ExcelApp);
GC.Collect();
GC.WaitForPendingFinalizers();
GC.Collect();
GC.WaitForPendingFinalizers();
To enable 'marshall', one should use:
using System.Runtime.InteropServices;
S.Rajendran from Coimbatore
24-Jan-14 7:01am
View
Thanks. It works.
S.Rajendran from Coimbatore
8-Jan-14 1:49am
View
Thanks. It solved my requirement.
S.Rajendran from Coimbatore
2-Jan-14 3:08am
View
As advised by you have already seen this link. And using that I tried in my code like:
//DateTime dateValue = new DateTime(2008, 6, 11);
//string v_d=dateValue.ToString("dddd");
//Console.WriteLine(dateValue.ToString("dddd")
I tried with the variable like: DateTime dateValue = new DateTime(v_DespatchDate);
It didnt work. The error is: Error 4 Argument '1': cannot convert from 'string' to 'long'.
I just wanted to know how that variable should be used.
Thank you.
S.Rajendran from Coimbatore
31-Dec-13 5:52am
View
Thanks. It worked. I used the 2 lines of yours.
if (shipping == "Not Eligible")
TB_Shipping.ForeColor = System.Drawing.Color.Red;
S.Rajendran from Coimbatore
30-Dec-13 21:50pm
View
I removed 'Autopostback=true' and changed the following 2 lines like this:
var rb = document.getElementById("<%=Radiobuttonlist6.ClientID%>");
var panel1 = document.getElementById("<%=Panel1.ClientID%>");
This worked. Thanks.
S.Rajendran from Coimbatore
30-Dec-13 10:24am
View
This I used , not working:
<script type="text/javascript">
function Validate(Radiobuttonlist6) {
for (var i = 0; i < Radiobuttonlist6.rows.length; ++i) {
if (Radiobuttonlist6.rows[i].cells[0].firstChild.checked) {
if (Radiobuttonlist6.rows[i].cells[0].firstChild.value == "This") {
document.getElementById('Panel1').style.display = "none";
}
else
document.getElementById('Panel1').style.display = "block";
}
}
}
</script>
<asp:RadioButtonList ID="Radiobuttonlist6" onclick="Validate(this);" runat="server" xmlns:asp="#unknown"
RepeatDirection="Vertical" style=" margin-left:10px; margin-top:44px" >
<asp:listitem>This
<asp:listitem>That
<asp:panel id="Panel1" runat="server" width="33" style="border-style:groove; height:30px; background-color:Red; margin-top:73px" xmlns:asp="#unknown">
I changed certain things like to Radiobuttonlist6 etc
S.Rajendran from Coimbatore
30-Dec-13 10:21am
View
This I used (not working):
<script type = "text/javascript">
function Validate(rb, panel1) {
var rb = document.getElementById('Radiobuttonlist6');
var panel1 = document.getElementById('Panel1');
var rblist = rb.getElementsByTagName("input");
for (var i = 0; i < rblist.length; i++) {
if (Radiobuttonlist6list[i].checked) {
if (Radiobuttonlist6list[i].value == "this") {
panel1.style.display = "block";
}
else if (Radiobuttonlist6list[i].value == "that") {
panel1.style.display = "none";
}
}
}
}
</script>
<asp:RadioButtonList ID="Radiobuttonlist6" runat="server"
RepeatDirection="Vertical" AutoPostBack="true" onclick="Validate('Radiobuttonlist6','Panel1')" style=" margin-left:10px; margin-top:44px" >
<asp:listitem text="this" value="this">
<asp:listitem text="that" value="that">
<asp:Panel ID="Panel1" runat="server" Width="33" style=" border-style:groove; height:30px; background-color:Red; margin-top:73px">
protected void Page_Load(object sender, EventArgs e)
{
this.Panel1.Style.Add("display", "none");
//this.Radiobuttonlist6.Attributes.Add("Checked", "Validate()");
}
S.Rajendran from Coimbatore
30-Dec-13 7:27am
View
Using your guidance, I apllied like this but doesnt work. At certain lines I changed panel to Panel1 and rb to Radiobuttonlist6.
<script type = "text/javascript">
function Validate(rb, panel1) {
var rb = document.getElementById('Radiobuttonlist6');
var panel1 = document.getElementById('Panel1');
var rblist = rb.getElementsByTagName("input");
for (var i = 0; i < rblist.length; i++) {
if (Radiobuttonlist6list[i].checked) {
if (Radiobuttonlist6list[i].value == "this") {
panel1.style.display = "block";
}
else if (Radiobuttonlist6list[i].value == "that") {
panel1.style.display = "none";
}
}
}
}
</script>
<asp:RadioButtonList ID="Radiobuttonlist6" runat="server"
RepeatDirection="Vertical" AutoPostBack="true" onclick="Validate('Radiobuttonlist6','Panel1')" style=" margin-left:10px; margin-top:44px" >
<asp:listitem text="this" value="this" xmlns:asp="#unknown">
<asp:listitem text="that" value="that" xmlns:asp="#unknown">
<asp:Panel ID="Panel1" runat="server" Width="33" style=" border-style:groove; height:30px; background-color:Red; margin-top:73px">
code behind:
protected void Page_Load(object sender, EventArgs e)
{
this.Panel1.Style.Add("display", "none");
this.Radiobuttonlist6.Attributes.Add("Checked", "Validate()");
S.Rajendran from Coimbatore
30-Dec-13 4:43am
View
Previously, for Checkbox we use '.checked' and 'onClick' in client side. Like that what is for RBL6. In RBL6 , I have 2 items (a,b). If 'a' is selected I want to show 'Panel1'. If 'b' is selected I want to hide 'Panel1'. This Panel1 is in separate <div>.I used the following code :
<script type="text/javascript" language="javascript">
function ShowAddressOrGuestPanel() {
if (document.getElementById('<% = Radiobuttonlist6.ClientID %>').checked == 'a')
document.getElementById('<% = Panel1.ClientID %>').style.display = "block";
else
document.getElementById('<% =Panel1.ClientID %>').style.display = "none";
}
</script
this.Radiobuttonlist6.Attributes.Add("onClick", "ShowAddressOrGuestPanel()");
S.Rajendran from Coimbatore
29-Dec-13 20:53pm
View
Well. Now it works. It was my mistake as I didnt remove a bracket. Thank you for your support.
S.Rajendran from Coimbatore
29-Dec-13 20:43pm
View
Well. I used the line 'document.getElementById('<% = RBL6.ClientID %>').style.display = "block";'
It works. Thanks. But if I use:
if (document.getElementById('<% = MyCheckBox.ClientID %>').checked == true)
document.getElementById('<% = RBL6.ClientID %>').style.display = "block";
else
document.getElementById('<% = RBL6.ClientID %>').style.display = "none";
}
it is not working. I hope something has to be done at 'if (document.getElementById('<% = MyCheckBox.ClientID %>').checked == true)' with regard to '.checked'.
S.Rajendran from Coimbatore
29-Dec-13 11:10am
View
As told by you, I did. Not working. I did like this;
<script type="text/javascript" language="javascript">
function ShowRBL6() {
document.getElementById("RBL6").style.display = "";
}
</script>
protected void Page_Load(object sender, EventArgs e)
{
this.RBL6.Style.Add("display", "none");
this.MyCheckBox.Attributes.Add("onClick", "ShowRBL6()");
}
Show More