|
since \ is a special character hence use \\t for one tab.
SAMir Nigam
|
|
|
|
|
The confusion may come from the fact that this is a language specific question that you didn't post in a language specific forum.
What programming language are you using?
---
b { font-weight: normal; }
|
|
|
|
|
asp.net (VB)
Best regards,
Chee ken
|
|
|
|
|
ASP.NET is not a programming language, it's a platform, so the language would be VB.NET.
VB doesn't use escape sequences in strings, so you have to use the Chr method to add tab characters:
Dim s As String<br />
s = "here" & Chr(9) & "are" & Chr(9) & "some" & Chr(9) & Chr(9) & Chr(9) & Chr(9) & "tab" & Chr(9) & "characters"
---
b { font-weight: normal; }
|
|
|
|
|
Hii all,
i am confused in which board i have to ask this.. it's related to some logic problem.
i am using asp.net and oracle database.
i need help to write a sql to check the existed data is matching with the input data.. the problem i am facing is i have a amount filed, which is having different values to each slab setting.
ex:
slab 1: 1-1000 the amount is 20
slab 2: 1000-2000 the amount is 25..
like this.
my problem is restricting user to enter the valid rage only. how do i check the the rage specified is existed in the database. user should not enter in between on range also..
what i mean is suppose if ihave already 1-1000 slab then i should not allow user to enter 500- 1000 again..
I'm trying with slabfrom >= and slabto<= which is not giving what i require..
can any body suggest how to do this??
thanks..
Smile..
|
|
|
|
|
I guess you need a custom validator, which uses data from the database to validate entry.
Christian Graus - C++ MVP
|
|
|
|
|
Thank you for ur response mr. Chirstian graus. i donot know how to create custom validator.. abd i d't have time to R&D. if you can suggest me how can i do it other way..
this is the sql code i am using
sqlstr = "Select SLABFROM, SLABTO from SLABLIST " _
& " where USERID='" & GlobalVars.SessionUser & "' and (slabfrom>=" & slbfr & " and slabto<=" & slbto & ")"
which is in for loop for the grid items.
Pls. give me some sort of solution..
Thanking you.
|
|
|
|
|
A custom validator is not R&D, it's a basic control provided by the framework. You create code in the code behind to set if the validator is valid, it can make a DB call and check if the value being passed in is valid, based on what's in the DB.
Someone gave you a 1, presumably because you're asking me to do your job. It wasn't me, but really, if you don't know how to do this stuff, and you don't have the time to learn, then either you shouldn't be doing the project, or your schedule is unreasonable.
Christian Graus - C++ MVP
|
|
|
|
|
Hello,
I have an assembly with customs controls, classes and handlers.I am creating it as an ASP.NET 2.0 VS2005 Web Project
This one one of my handlers:
Namespace Web
Public Class SiteMap : Implements IHttpHandler
Public Sub ProcessRequest(ByVal context As HttpContext) Implements IHttpHandler.ProcessRequest
Dim xslDoc As XslCompiledTransform = New XslCompiledTransform
xslDoc.Load(Page.ClientScript.GetWebResourceUrl(Me.GetType, "MyProjectNamespace.Web.SiteMap.xsl")) >>> ERROR
End Sub
...
I get the error "Page is not declared".
I also have the code line "<Assembly: System.Web.UI.WebResource("MyProjectNamespace.Web.SiteMap.xsl", "text/xml")> " in my AssemblyInfo.vb file.
And I set the Build Action of "SiteMap.xsl" to "Embedded Resource".
I have been reading documentation in internet but I can't find the solution.
Could someone help me out?
Thank You,
Miguel
|
|
|
|
|
I am trying to create advanced search page where a user can select values from multiple dropdown controls. There is a stored procedure that will take the selected values from dropdown boxes using coalesce. I was able to configure it so the data fromdropdown boxes is read from SQL Express 2005 database and available for selection from drop-down boxes. I created a "Search" button that will submit these selected vaules from multiple dropdown boxes and submit these to store procedure. After user clicks on a search button the data is supposed to be displayed in a data grid. Can someone help me how to program Button logic for this? So a click on a search button dispalys the "found" data in a grid? This is what i have now:
None of these 2 alternative will fire.. I have SqlDataSource1 throygh SqlDataSorce6 for dropdown boxes.
protected void Button1_Click(object sender, EventArgs e)
{
gridDataSource.Select(DataSourceSelectArguments.Empty);
}
protected void Button1_Click(object sender, EventArgs e)
{
SqlDataSource1.Select(DataSourceSelectArguments.Empty);
}
|
|
|
|
|
Hi,
How do I allow users to enter their username and password into the Address bar as a sring rather than having them enter the information directly into a form?
http://www.site.com/login.aspx?user=Fred&pass=George
Thanks,
Ash
|
|
|
|
|
ednet2006 wrote: How do I allow users to enter their username and password into the Address bar as a sring rather than having them enter the information directly into a form?
That really is not a good idea.
|
|
|
|
|
Can you recommend any way to automate the login procedure?
|
|
|
|
|
ednet2006 wrote: Can you recommend any way to automate the login procedure?
The keywords you are looking for are "Forms Authentication" - There are a couple of good exampled on the MSDN website.
|
|
|
|
|
hi,
1)on the event of clicking button on a page i've to open print dialogue box to print the page on which that button is.
and
2) on clicking Link button showing emailId i've to open Outlook express.
How can i achieve it?
Please guide.
yog
hui gfgh kgdgrt njjn hjgkn
|
|
|
|
|
(1) - javascript:print()
(2) -<a href='mailto:g_parwej@rediffmail.com'> Mail to link </a>
Keep Smiling !!!
Parwej Ahamad
g_parwez@rediffmail.com
|
|
|
|
|
i have one variable in double type, let say :
a = 123.45
b = 78.20
how to i convert it become 00000012345 and 00000007820?
Best regards,
Chee ken
|
|
|
|
|
Hi,
You will have to multiply by 100. Then convert to string. And padd number of 0's before the string. These number of zeros depend on length of the string you just created !
"A good programmer is someone who looks both ways before crossing a one-way street." -- Doug Linder
coolestCoder
|
|
|
|
|
Multiply by 100, and use the format string "00000000000" to format them.
---
b { font-weight: normal; }
|
|
|
|
|
How to use the format string "00000000000" ?
Best regards,
Chee ken
|
|
|
|
|
For example in the String.Format method:
String s = String.Format("{0:00000}", someValue);
or in the ToString method:
String s = someValue.ToString("000000");
---
b { font-weight: normal; }
|
|
|
|
|
You can do it as following too:
Dim Formatted_a As String, Formatted_b As String
Const a As Double = 123.45
Const b As Double = 78.2
Formatted_a = Format(a * 100, "00000000000")
Formatted_b = Format(b * 100, "00000000000")
Eric H.
|
|
|
|
|
I get it ! thanks for reply !!
Best regards,
Chee ken
|
|
|
|
|
i want to write data into .txt file, so i using :
Dim objSWriter As New StreamWriter(.....)
objSWriter.Write(EmployeeNumber & " " &EmployeeName & " " & EmployeeAddress)
Since every employee name's length is not same, so the result at text file will be :
xxxxxx xxxxxxxxxxx xxxxxxx
xxxxx xxxxxxxxxxxxx xxxxxxx
xxxxxxxx xxxxxxxxxxxxx xxxxxxx
So i need to format the style of displaying data become :
xxxxxxxxx xxxxxxxxx xxxxxxxx
xxxxxxxxx xxxxxxxxx xxxxxxxx
xxxxxxxxx xxxxxxxxx xxxxxxxx
How to make this type of display format ?
Best regards,
Chee ken
|
|
|
|
|
Hi,
I think when you want formatted result, you already have set in mind the length of each fields. Just use some paddings. For this write a function which will take the value as input and add number of spaces to the left so that when you write it to a text file it looks formatted.
You can decide which type of padding you require. Left or right.
Hope i am clear enough !
"A good programmer is someone who looks both ways before crossing a one-way street." -- Doug Linder
coolestCoder
|
|
|
|