15,886,030 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 Python 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 alexvw (Top 39 by date)
alexvw
25-Feb-19 9:22am
View
Hi there,
Almost; in your code you are using the same variable over and over: OrderNum will have the last value assigned to it.
It should be something like this:
string OrderNum = ((Label)iRow.Cells[0].Controls[1]).Text;
string OrderDate = ((Label)iRow.Cells[1].Controls[1]).Text;
etc...
CAUTION! if you are reading data from a cell that does not have a label or any other control inside of it, just read its text property:
string anotherVar = iRow.Cells[3].Text;
Cheers!
alexvw
6-Feb-19 15:18pm
View
Hi Anilananda,
ClientIDMode = "Static" does not reach the control's rendered name, that's why you can see the "ctl00$ContentPlaceholder1$txt1language" on the client's side.
There is a method, that I know of, to change it, but requires the creation of your own control, which must inherit the proper base class, e.g. TextBox, Lable, etc.
In your implementation, you would have to override the attributes (if I recall right) method that writes them out. In there, you would have to detect the name attribute and overwrite or replace it with the one you want.
I have never had time to get into that much of a detail.
Anyways, DO NOT attempt to replace you control's names in the response object, for such thing will invalidate all events for said controls.
Cheers!
alexvw
5-Feb-19 11:41am
View
Hi there,
The change you are seeing in your control's id is standard behavior of ASP.NET WebForms. Its purpose is to make sure your controls have a unique id.
You can change this by setting the ClientIDMode property at either page or control level; e.g.
Page Level:
<%@ Page Title="TestPage" Language="C#" MasterPageFile="~/UserMaster.master" AutoEventWireup="true" CodeBehind="test.aspx.cs" Inherits="project.test" ClientIDMode="Static"%>
Control Level:
<asp:TextBox ID="txtLanguage" runat="server" ClientIDMode="Static">.
Careful with this! if you set it up a page level, it will be up to you to ensure your controls have unique ids, otherwise, no javascript will work as expected, for it will not know how tell which control you what it to work on.
Hope this helps.
alexvw
5-Feb-19 11:35am
View
Hi there,
RootCore is a helper class I add to my projects, where I write methods that are of general interest/accessibility throughout the code.
The SetDisplayStyle method you can see, in the code example I sent you, is in charge of setting the display attribute of the style property of the signaled control. e.g. { style="display:none;" }
Cheers!
alexvw
1-Feb-19 14:32pm
View
Hi there,
I am afraid I can't give you a hand with Crystal Reports; I have not use them in more than 10 years.
Sorry.
alexvw
7-Dec-18 12:09pm
View
Hi there,
Is there a particular reason you are trying to capture the GUID object per se, instead of just its string representation?
Also, you ObjExamBO.ExamId property, what type is it? both of them should be the same.
Try:
Session["ExamID"] = Guid.NewGuid().ToString();
ObjExamBO.ExamID = (string)Session["ExamID"];
By the way, it would be better if you share your page markup/code behind; if for some reason you are clearing that session variable in between, there is no way for anybody to see it.
Cheers!
alexvw
27-Nov-18 14:12pm
View
Hi there, are you attempting said navigation from client-side or server-side code?
alexvw
27-Nov-18 14:10pm
View
Hi there,
The code you posted, seems to be a copy-paste extract of "Walkthrough: Printing a Local Report without Preview" (https://msdn.microsoft.com/en-us/library/ms252091.aspx).
Since it is not complete, it would quite hard for someone to offer useful help. The fact that said walkthrough targets a console application should not be an inconvenient.
Please, share all the relevant code, and error message(s) you may be getting with the community, so that you can receive adequate help.
alexvw
20-Nov-18 14:57pm
View
Hi there,
You may also what to take a look at this:
https://www.w3schools.com/tags/tag_datalist.asp
but, BEWARE OF BROWSER COMPATIBILITY.
Click the "Try it Yourself" and see it working, I never got to use it, but it may serve your purpose.
Cheers!
alexvw
19-Nov-18 8:14am
View
Hi Rajesh,
Could you rephrase your question; what is it what you are trying to accomplish? What is it not working as expected? is there an error message?
Just copying a portion of code in both the question and in the "What I have tried" sections is not enough for others to understand and help.
Cheers!
alexvw
19-Nov-18 8:09am
View
Hi there ZurdoDev,
I have; but cannot pin-point the issue; as previously explained "...keystrokes work as expected, but not the mouse. I implemented javascript to allow navigation using arrow keys, pressing Enter, Tab, and they all work just fine."
The issue remains; the mouse seems to become "inactive", forcing a click to "re-enable" it.
Thanks for your input.
alexvw
16-Nov-18 12:20pm
View
Good question! Vincent.
I can now tell how tired I am; it did not occur to me to verify that (which I usually do). And it is constant in all Browsers = it is not the browser, it is my code. (Tested: FF, Opera, Chrome, Vivaldi, Brave, Safari, IE, Edge)
There must be something somewhere I am just not being able to see now (tunnel vision I hope). I also noticed that several bootstrap classes: col-this, col-that, in some sections are also giving trouble (they used not to). This must be something I did or did not do after changing the ClientIDMode, for it was not like that.
I now know I must not look for odd things, but to review the entire Id situation (and the ViewStateMode, which I have also been messing with).
Thanks for your insight. Have a great weekend.
Cheers!
alexvw
16-Nov-18 9:44am
View
Hi Vincent, thanks for your input.
I did verify all css/javascript and code behind, without any luck. Any control reference was always set to control.ClientId (not using hard-coded ids).
I just can't pin-point why the focus is set (where I want), keystrokes work as expected, but not the mouse. I implemented javascript to allow navigation using arrow keys, pressing Enter, Tab, and they all work just fine.
The issue is limited to the mouse pointer; also noticed that no matter where I set the focus using the keyboard, the very next mouse click will always send the focus to the same unintended control.
Will continue to scratch my head!
alexvw
14-Nov-18 13:48pm
View
Hi there,
That does not seem to be related to text alignment, but textbox (objects) positioning. There must be something either in your data or another object that is causing those ones to move around.
In your images, the displacement of the "SPETT.LE" section, as well as the "Totale Offerta", are evident.
Question: does it always happen only when the "OGGETTO" line is visible? If so, look into the rdlc's graphic design to pin-point the issue with said line.
Cheers!
alexvw
7-Nov-18 9:05am
View
Hi there,
Run a search along the entire solution of "Session["SomeName"]", there must be a line of code that is clearing it (given certain circumstances), which are obviously not so evident.
Cheers!
alexvw
22-Oct-18 15:23pm
View
Hi Lee,
The behavior you describe is related to either the T-SQL or the value of the parameters being passed. Double check those.
Cheers!
alexvw
20-Jul-18 16:56pm
View
Hi there,
The message indicates that you dt (datatable object) is not instantiated/loaded before being passed to the report. I'd set a breakpoint right there and make sure dt is not null.
Moreover, did you make sure your rdlc's dataset name matches the one you are referencing?
....ReportDataSource("CashReport_DataSet", dt));
Cheers!
alexvw
18-Jun-18 16:19pm
View
Hi there,
From what I can see on Mike's comment, your "scenario's" description might need some re-writing.
Please, correct me if wrong. I believe you are not trying to use each image control's unique ClientId to link it to its target image, but rather an int Id value that somehow you have associated (or need to associate) to each image control.
I would assume said int Id value would match the name of its target image file (intIdVal.svg/png), which in turn would make it easier to generate the required URL to recover/find the file to load. In this case, changing URLS based on "int value of a specific table in the database" would be a matter of just of re-associating those int values to each image control, and then load the page (with the new set of images).
In a desktop scenario I have used a control's tag property to store data of that sort, e.g. the int Id key. But, in a webpage, there is no such thing; you may have to device a way to do it such a list, array or another suitable container, which most likely will have to be attached to the user's session.
Hope this helps; cheers!
alexvw
13-Jun-18 11:56am
View
Hi there an0ther1,
Thank you for your input; I actually have taken that step before, but since you brought it up, I decided to check it again with a fresh mind.
For as embarrassed as I now feel, it turns out to be that production web.config file had the wrong set of credentials. As simple as that!
If you post your suggestion as answer, I will be more that happy to rate it as correct. Once again, thank you for your help.
alexvw
13-Apr-18 12:21pm
View
Ok, thanks. Have a nice day. If it is fine with you, re-post your insight as an answer so that I can rate it.
Cheers!
alexvw
13-Apr-18 11:36am
View
Hi there, thank for your input. Would it possible for you to offer some "valid/appropriate" metric gathering methods which would render proper insight.
Basically, what should I try to measure rather than overall execution time?
alexvw
13-Mar-18 14:32pm
View
https://msdn.microsoft.com/library/system.web.ui.page.ispostback(v=vs.110).aspx
alexvw
13-Mar-18 14:31pm
View
Deleted
https://msdn.microsoft.com/es-es/library/system.web.ui.page.ispostback(v=vs.110).aspx
alexvw
12-Mar-18 9:35am
View
Hello Member 13700339,
In order for someone to help you, your question must be recomposed.
What do you mean by "counter animation"? your code does not provide obvious clues of any attempt to generate an animation per se.
Here's what we see:
1) On page_load, the existence of a file is checked.
a)If if does not exists, a "File does not exist" message is offered to the user.
b)If the File exists, its contents are read and used to populate the List<tring> testFileLines object.
2) On Button1_Click, an attempt to get a random item (string) from testFileLines object, is performed and its results shown by Label1. After this, said result is removed from the list.
/* Comments to Consider */
Since you are populating testFileLines on you Page_Load, it gets repopulated in full every time you hit the button. To avoid this, you need to implement/validate IsPostBack on Page_Load, otherwise, the "testFileLines.Remove(randomLine);" command is completely ineffective.
The community needs to understand your need so that it can help.
alexvw
9-Jan-18 14:45pm
View
Hi Dirk,
I glanced the article, although it seems quite extensive in terms of reading/writing xml data, it does shed light on my issue about building a rdlc an populating it using nested matrices from several datasets.
Thanks as lot anyway; I appreciate your willingness to help.
alexvw
4-Dec-17 11:10am
View
I just figured out where do Modulus and Exponent come from. i.e. They are obtained by means of the RSAKeyValue class, passing the certificate's private key as param:
KeyInfo keyInfo = new KeyInfo();
keyInfo.AddClause(new RSAKeyValue((RSA)privateKey));
alexvw
30-Nov-17 13:33pm
View
Hi there,
To get started, the following must be known:
a) You must seriously consider modifying your code to avoid
...
string searchQuery = "select * from StudentTB where PID='" + txt_pid.Text + "'";
...
for this is an open door to SQL Injection Attacks.
b) Where and how do you load your CheckBoxList_hobby? Are they hard-coded in the page or loaded from DB?
c) What do you intend to do with your hobby string array? it is declared and initialized, but there does not seem to be any use for it.
Perhaps, the answers to these questions will help someone to offer further help.
Cheers!
alexvw
21-Nov-17 7:00am
View
Hello Grant,
Thanks for your suggestion; unfortunately, I had already reviewed MS documentation, and spent some time searching the web to no avail.
"nested tags" are not a problem, the issue at hand is: nested tags with the Same Name, which would result in two or more datatables with identical names. According to MS documentation, such scenario is not allowed inside a dataset unless such tags(tables to be) can be identified by means of different namespaces.
Obviously, the xml content I am receiving from the source, does not declare namespaces, nor will they rename the offending tag. This, leaves me no choice but to come up with some sort of "hack" to deal with it.
Last night I put together a workaround, which involves using regexs and string manipulation to modify the source data before attempting to load it into the dataset, but from my point of view, this is something that should not be done to begin with.
alexvw
8-Nov-17 15:55pm
View
Hello Karthik, good day.
I have tried your suggestion, i.e. removing the call to
Sys.WebForms.PageRequestManager.getInstance().get_isInAsyncPostBack()
and for the initial tests, it seems to work. By this I mean, it allows the popup to work as expected in the two other pages where it had stopped working. Can you elaborate on the reason why this behavior?
Also, how can I mark your reply as answer and rate it? ;) Thanks a lot!
alexvw
6-Nov-17 11:01am
View
Hello Karthik; both Content Pages contain Update Panels, and both user controls reside inside of them.
alexvw
19-Oct-17 6:34am
View
The source is a char (100) field, which contains various length values not larger than 50 characters.
It was decided to dump them into a varchar column (60 in length) thus leaving room for unforeseen larger values. Hence, the Cast.
alexvw
19-Oct-17 6:17am
View
Good morning Richard, it is not a
specific value; it's come up with various records (not necessarily the same ones). Anyway, these are simple strings. The source is:
Select Cast(Trim(field01) as varchar(60)) as InputValue
From dbo.sourcetable
The destination table field is declared as varchar(60).
All values get inserted without issues, but the described error ramdomly appears during updates and only in the production environment. By the way, it even comes up when trying to update the inserted record with it own values.
Oddly, that same data and SSIS do not cause incidents while operating in development environment.
Sorry I can't be more specific; oh! I can say these strings do not have troubling characters such as: ', ", --, ; , etc.)
Anyhow, thank you for looking into it. I'll make sure to share any findings on my side.
alexvw
29-Jun-17 12:46pm
View
Thanks a lot for the clarification; I do not recall ever seeing it before. Now, it is time to find the true reason for my real problem.
Cheers!
alexvw
7-Jun-17 10:16am
View
Hello Karthik, thank you for your suggestion; unfortunately, it makes no difference. After doing some more extensive reading I came across something that solved the issue. I will publish it as answer in a few minutes.
Cheers!
alexvw
19-May-17 9:02am
View
Short after I read your first message, I came to think that. If we could just do it, then it would not be secure after all.
Now I know I must look for a different way. Is it possible for a SSL enabled site to request client certificates (the formal way = through browser) for certain page along the way rather that from the start?
alexvw
18-May-17 21:27pm
View
Hi Dave, thanks for your input.
Here's a quick and small update; I was told about an hour ago that we just need to read the client's certificate to obtain two values (CN and another one) to use them as credentials to consume a third party's web service. Does that make sense?
I thought we could somehow read client's certificate(s), and ask (the client) which one to use for such purpose. How that does sound?
alexvw
6-Mar-11 13:14pm
View
SAKryukov,
You are right, I failed to research about these methods before posting in here. There are indeed overloads with timeout parameters.
Thank you for you direct attention call.
alexvw
22-Oct-10 19:30pm
View
Hello Ted2102, thank you for your insight. I am afraid that all machines have both the SP3 and .Net frameworks properly installed. I have been working with it some and I still have issues when attempting to save all files to the user's C: drive, and a few hurdles that seem to be related to .dll reference paths.
alexvw
22-Oct-10 19:25pm
View
Hello Abhinav, Thank you very much for pointing me in this direction. It seems very promising.
Show More