I'm creating a Shared (static) method in ASP.NET MVC so it can be used by any controller in my project. This static method needs to generate a URL. I think I need to use System.Web.Mvc.UrlHelper, but I can't figure out how to call it from within a static method. The constructor seems to want a RequestContext. Any ideas?
...
Stack Overflowers:
I have a search function on my company's website (based on .NET 2.0) that allows you to narrow the product catalog using up to 9 different fields. Right now, after you make your selections on the frontend I am building a dynamic query and hitting the database (SQL Server) to get the resulting list of items numbers.
...
I'm writing a GUI-based app in VB.net that talks to a LambdaMOO server via telnet, sends commands to display the object hierarchy, then parses the output and creates a visual representation of the object hierarchy.
So my question is: is there some kind of "telnet client" class for .NET to simplify the sending and receiving of data, or d...
If I want to narrow scope of a variable in C#, I can introduce additional braces - i.e.:
class Program
{
static void Main(string[] args)
{
myClass x = new myClass();
x.MyProperty = 1000;
Console.WriteLine("x = " + x.MyProperty);
{
myClass y = new myClass();
y.MyProperty = ...
I come from a C# background but am now working mostly with VB.Net. It seems to me that the above functions (and others - eg. UCase, LCase) etc. are carryovers from VB6 and before. Is the use of these functions frowned upon in VB.Net, or does it purely come down to personal preference?
My personal preference is to stay well away from th...
hi,
Is there a way to use wheel mouse and scroll vertical bar without actually get focus on datagridview in vb.net?
andrew
...
I have seen a couple of websites that have a dynamic download link.
They ask for a valid email address and send the dynamically created download link to that address.
E.X. www.mysite.domain/hashvalue1
But how they do that, since the file exists on the domain in a specific location?
www.mysite.domain/downloads
Is there any guide around...
I'm using the following code to work out the next unique Order Number in an access database. ServerDB is a "System.Data.OleDb.OleDbConnection"
Dim command As New OleDb.OleDbCommand("", serverDB)
command.CommandText = "SELECT max (ORDERNO) FROM WORKORDR"
iOrder = command.ExecuteScalar()
NewOrderNo = (iOrder + 1)
If I subsequently creat...
I'd like to be able to create, name and store individualized reports (school report cards, actually) with VB.Net and Crystal Reports using data from our SQL database.
It would be even better to be able to automatically generate individualized e-mails using e-mail addresses stored in the database, attaching the aforementioned PDF reports...
I am comfortable with Vb.Net events and handlers.
Can anybody will help me with how to create event handlers in c#, and raise events.
...
Before answering this question, understand that I am not asking how to create my own programming language, I am asking how, using vb.net code, I can create a compiler for a language like vb.net itself. Essentially, the user inputs code, they get a .exe. By NO MEANS do I want to write my own language, as it seems other compiler related qu...
The company I work for is looking for the best way to track "tech calls". We would most likely develop in house using vb.net, but possibly could look at using some open source vb.net software already out there.
We will probably want to track just the basic info like client, datetime, length of call & a notes section about the call.
On...
What's the easiest way in VB.NET to parse this XML?
Here's an example of the full source:
View Source XML
I believe that the XML can be read directly into a class structure that matches the XML's structure.
Let's take a bit of the XML from the above example,
<?xml version="1.0" encoding="UTF-8" ?>
- <kml xmlns="http://earth.goog...
Hi,
I am working on building a CMS, my client's specific request was that he should be able to modify/edit the nav menu and its contents using the user interface, I am not sure how to do it.
Can someone please help by providing links to articles where I can learn? or even examples that I can implement?
Site2you.com has a template t...
Dear Friends,
I have a Scanned PDF Files , i need a VB.net Source Code which convert that scanned PDF to text Format.
Plz Help me...
Thanx in Advance
...
I need to create an ASP.NET application to access a URL, when this application is live it is able to access the feed URL correctly as the clientaccesspolicy.xml and crossdomain.xml are on the server but only allow non-localhost connections so the debug version won't connect.
How do I create a file, so this kind of link:
http://localhost...
Hi,
I want VB.NET regular expression for below format
7966-591739
I mean user must have to enter 4 numeric characters first then "-" and then 6 numeric characters after that optional for numeric as well as for characters. In my case user can also enter
7966-591739 ext 562
7966-591739 x 434
Please suggest!
...
How to handle the Network failure error message,and how to simulate it?
...
Hi,
After inserting into masterTable it returns an ID. With that ID I want to enter more than one row into a transaction table.
I am using two separate procedures. The problem is, after inserting the record into master, and while inserting into the transaction table, if any interruption occurs I want to abort the corresponding insert o...
Hey,
im working with a receipt layout and trying to divide up a products descriptiontext into 2 lines if its longer then 24 characters.
my first solution was something like this:
If Row.Description.Length >= 24 Then
TextToPrint &= Row.Description.Substring(0, 24) & " $100"
TextToPrint &= Row.Description.Substring(24) & vbNewLine
e...