|
|
LOL, that's everything he's using!
I think a basic class on ASP.Net is in order. I hope somebody isn't paying for this!
|
|
|
|
|
I Higly recommend you to use an Identity column or a UniqueIdentifier Column and set it as Primary Key.
Heap tables with equal row data have this problem due to uniqueness is null and SQL Server nor you could identify which record is fine.
|
|
|
|
|
I am a beginner with asp and I want to start to build professional sites. I had a look at some books and links href="http://www.w3schools.com/aspnet/">
I am more than confused on where to start. I see no structure in my mind
Is there some guidance or strategy, not only a list of technologies available?
Question1:
There is the tool "WebMatrix". It seems to support any needs. Why do I need VStudio then? What is the difference from WebMatrix and VStudio
Question2:
There seems to be a principal difference between "WebPages" and "WebForms (&MVC)". What is this difference
|
|
|
|
|
|
|
|
I want to create yes/no buttons in a popup menu any ideas regarding this?
|
|
|
|
|
Are you looking for simple javascript popup ?
You can try
var r=confirm("Are you sure?");
if (r==true)
{
x="You pressed OK!";
}
else
{
x="You pressed Cancel!";
}
But here you will see OK and cancel instead of yes/no.
|
|
|
|
|
I want code about "how to create setup file in asp.net/c#"
|
|
|
|
|
|
Here's the problem :
When the gvWorkReportList is invisble and gvWorkReportList.FooterRow =null in page loading i get the bellow error :
Quote: System.NullReferenceException: Object reference not set to an instance of an object.
the error is on this part of code :
__doPostBack('<%=gvWorkReportList.FooterRow.FindControl("lnkAdd").UniqueID%>', '');
Quote: this is the piece of my code!
<script type="text/javascript">
function KeyDownHandler() {
// process only the Enter key
if (event.keyCode == 13) {
__doPostBack('<%=gvWorkReportList.FooterRow.FindControl("lnkAdd").UniqueID%>', '');
}
}
</script>
This doesn't seem like it should be that hard, so if someone could just give me a kick in the right direction, that'd be awesome.
I have used these solution but it dosen't work :
var grid = document.getElementById('<%=gvWorkReportList.FooterRow.FindControl("lnkAdd").UniqueID%>');
if (grid != null) {
__doPostBack('<%=gvWorkReportList.FooterRow.FindControl("lnkAdd").UniqueID%>', '');
}
var grid = document.getElementById("ctl00_ContentPlaceHolderContent_gvWorkReportList");
if (grid != null) {
__doPostBack('<%=gvWorkReportList.FooterRow.FindControl("lnkAdd").UniqueID%>', '');
}
var gridFooter = gvWorkReportList.FooterRow;
if (gridFooter != null) {
__doPostBack('<%=gvWorkReportList.FooterRow.FindControl("lnkAdd").UniqueID%>', '');
}
|
|
|
|
|
Hi,
if the gridview is invisible i.e. you have made visible = "false" , the control will not be rendered into the client, and object will go null. So, this is what happening in your case.
if you want the gridview to be rendered into the client but not to be displayed, then try by using style attribute like this. style = "display: none;" . if you do so, probably you can access UniqueID .
hope it helps.
Vande Matharam - Jai Hind
|
|
|
|
|
thanks for solution.
But i dont need to get access when it is invisible.
How i can control it if gridview in invisible the the code
__doPostBack('<%=gvWorkReportList.FooterRow.FindControl("lnkAdd").UniqueID%>', '');
doesnt run.
Thanks in advanced!
|
|
|
|
|
Hi,
try like below.
var grid = document.getElementById('<%=gvWorkReportList.ClientID%>');
if (grid != null) {
__doPostBack('<%=gvWorkReportList.FooterRow.FindControl("lnkAdd").UniqueID%>', '');
}
hope it works.
Vande Matharam - Jai Hind
|
|
|
|
|
not used!
Cause :
var grid = document.getElementById('<%=gvWorkReportList.ClientID%>');
is not null .
but this code :
gvWorkReportList.FooterRow
is null.
Thnaks in advanced!
|
|
|
|
|
Quote: <big>This doesn't seem like it should be that hard, so if someone could just give me a kick in the right direction, that'd be awesome.</big>
|
|
|
|
|
<textarea id="TextArea1" class="textarea" runat="server" ></textarea>
TextArea1.Value="erromessage <br/>"
after i do research i found set text on text area can be use .value but how about append? anyone know?
modified 19-Apr-13 14:08pm.
|
|
|
|
|
Is the obvious method not working?
TextArea1.Text = TextArea1.Text + "Something else";
|
|
|
|
|
There is no append method on the TextArea.
You would simply create the text you wanted to append, something like:
string current = TextArea1.Value;
string stringToAdd = "The quick brown fox jumps over the lazy dog";
string newString = current + stringToAdd;
TextArea1.Value = newString;
This is, of course, a very simplistic example but should give you the idea of how this works.
You are not appending to the control but to the text within the control.
"If you think it's expensive to hire a professional to do the job, wait until you hire an amateur." Red Adair.
nils illegitimus carborundum
me, me, me
|
|
|
|
|
no wonder i search few hours no have any answer on textarea thx u very much what is <asp:literal id="Literal1" runat="server">i never see this ...
but it still cant append, for my page i nid to do the validation if the user tick the checkboxA, it nid to few in the number on the textboxA, so every checkbox i set
OnCheckedChanged="CheckBoxXS1_CheckedChanged"
protected void CheckBoxXS1_CheckedChanged(object sender, EventArgs e)
{
if (textboxA.Text.Trim().Length == 0)
{
TextArea1.InnerText = "last"; (when result show i nid to append,how should i do? if i create a label it nid alot)
}
}
|
|
|
|
|
I've already done it in VB6 which was perfectly working fine but i've to work it in c#
for locking access database
Sub lockDb(bPath As String)
On Error GoTo Ermsg
Dim iFreeFile As Integer
Dim lLoop As Integer
Dim sString As String
iFreeFile = FreeFile()
Open bPath For Binary As #iFreeFile
sString = "DVUnion Windows Database"
For lLoop = 7 To 19
Put #iFreeFile, lLoop, VBA.Mid$(sString, lLoop - 4, 1)
Next lLoop
Close #iFreeFile
for unlock access database
Sub UnlockDb(bPath As String)
On Error GoTo Ermsg
Dim iFreeFile As Integer
Dim lLoop As Integer
Dim sString As String
iFreeFile = FreeFile()
Open bPath For Binary As #iFreeFile
sString = "Standard Jet DB"
For lLoop = 7 To 19
Put #iFreeFile, lLoop, VBA.Mid$(sString, lLoop - 4, 1)
Next lLoop
Close #iFreeFile
How to do it in c#
www.facebook.com/raazak47
|
|
|
|
|
|
That isn't what the OP stated.
VB6 is not VB.Net. Although it might be better if they convert it to VB.Net and stick to it.
"It's true that hard work never killed anyone. But I figure, why take the chance." - Ronald Reagan
That's what machines are for.
Got a problem?
Sleep on it.
|
|
|
|
|
A direct translation would give you something like this:
void LockDb(string bPath)
{
const string sString = "DVUnion Windows Database";
using (var fileStream = File.OpenWrite(bPath))
{
fileStream.Seek(6, SeekOrigin.Begin);
for (int index = 2; index < 15; index++)
{
fileStream.WriteByte((byte)sString[index]);
}
}
}
void UnlockDb(string bPath)
{
const string sString = "Standard Jet DB";
using (var fileStream = File.OpenWrite(bPath))
{
fileStream.Seek(6, SeekOrigin.Begin);
for (int index = 2; index < 15; index++)
{
fileStream.WriteByte((byte)sString[index]);
}
}
}
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|