Asp.net Mvc - Why Does Normal Markup Inside An @Using Html.BeginForm Need An @
Apr 19, 2012
When I make an HTML form for MVC 3/VB with the Razor engine, I would expect to be able to do it like this:
@Using Html.BeginForm("Action", "Controller")
<fieldset>
@* Other form code and values *@
</fieldset>
End Using
But if I do that I get "BC32035: Attribute specifier is not a complete statement. Use a line continuation to apply the attribute to the following statement." I need to add an @ character before the opening tag to avoid this error.
View 3 Replies
ADVERTISEMENT
Nov 21, 2010
net-late-binding-operations-cannot-be-converted-to-an-expression-tree errors VB.Net Late binding operations cannot be converted to an expression tree.I changes the page code from
<%@ Page Language="vb" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<Store.WebUI.Entities.ShippingDetails>" %>
to
<%@ Page Language="vb" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage(Of Store.WebUI.Entities.ShippingDetails)" %>[code].......
View 1 Replies
Jan 26, 2011
I'm working on this big project in MVC ASP.NET w VB.NET One of my views is getting me headaches since a few and i'm not sure what's up. I've used the Begin.Form and Html.Encode methods alot in my other views and i never had any problems. Now this new Create.aspx view for one of my object called Automation is giving me multiple build errors such as those cited in the title plus
Error 184 'Context' is not a member of
'ASP.views_automatisation_create_aspx'.
BeginForm is not a member of 'Html'
[Code]....
View 4 Replies
Dec 29, 2010
I'm new to custom server controls and I'm hoping to use them to build various 'modules' for different sites I build to cut down on duplicate code.
I'm familiar with custom user controls in which I can create an .ascx & .ascx.vb file which can then be imported into an .aspx page and used freely.
However, with custom server controls I cannot find a way of using markup/html code. Is this possible at all or must all code be created programmatically?
View 1 Replies
Apr 21, 2011
With my recent new project with HTML/Markup generator/editor, I have run into a roadblock. Basically here is my code for replacing markup with HTML. The way this works is that the webbrowser has the same text as RTB1. Since the Webbrowser supports HTML, it automatically converts to the style that is specified in RTB1. [Code]
View 4 Replies
Aug 1, 2011
How can I run or execute a html file that inside the DLL file?
View 1 Replies
Dec 10, 2007
I am writing a code to automate a webside. i succeeded in one website which have no frames. But if there is a frames, the code reads the element outside the frames.this code is used to get elements from one form a = f.IHTMLFormElement_item(count)How can we read the elements inside the frame?
View 2 Replies
Dec 2, 2011
I have a simple questionnaire system which shows a random number of questions to the user out of a certain total in my database.I have 2 separate tables: Questions and Alternatives (which are the options to answer) related by QuestionID field in both tables. I rendered such questionnaire using Nested Repeaters (parentRepeater for questions and childRepeater for the options) and it shows correctly on the page.Each option is a radio button which I had to use it as a HTML instead of the Standard Server Control <asp:RadioButton> because of the Dynamic ID problem inside a repeater.[code]What I don't know is how do I get all the questions answered by the user given that I don't know the QuestionIDs and the Alternative IDs since it's randomly generated and using a HTML input tags?
View 1 Replies
Sep 12, 2010
I need to app to go through all the elements <div class="address"> and check the length of the text inside it. if its less than or equal to 2, then it needs to skip the following line and check the next <div class="address">Here is my code:
Dim content As String = ""
Dim web As New HtmlAgilityPack.HtmlWeb
Dim doc As New HtmlAgilityPack.HtmlDocument()
doc.Load(WebBrowser1.DocumentStream)
'this is where I need to check if text inside divclass="address" is <= 2
Dim hnc As HtmlAgilityPack.HtmlNodeCollection = doc.DocumentNode.SelectNodes("//div[@class='address']/preceding-sibling::h3[@class='listingTitleLine']")
View 1 Replies
Feb 13, 2012
What I'm trying to do is click an html link inside of a html table via code in vb.net using a web-browser control. The link I want to click can be anywhere in the first column of the table so I need to cross reference with another column in the table to make sure I have the re way I'm going about this is to loop through the html elements till I find the table I want (multiple tables on the page) then dump that table to an array. Then loop through the page again get to the table I want and then start comparing the link and another column in the now array. I need to check to make sure that the url of the link contains a work and that another column in the table contains a specific or lower numerical value. Basically where I'm stuck is while dealing with the html element "Table" wanting to identify and interact with another html element inside it.
'Flag to say dump to array
Dim RecordFiles As Boolean = False
'The last two headers in the table are blank so need to skip them
Dim FirstBlank As Boolean = False
Dim SecondBlank As Boolean = False
[Code] .....
View 3 Replies
Oct 4, 2011
I have an enum and a usercontrol, both in the same assembly (a plain .NET 4 web site). In the Constants class:public Enum CrudOperations Add Edit Delete. This controls the columns in a GridView on a UserControl via a property on the UserControl
[Code]...
In C#, I've specified the columns to show with markup as Mode="Edit,Delete", but in VB.NET, this does nothing. The only way I can get anything to show is with the codebehind, but if on the containing page I use userGrid.Mode = CrudOperations.Edit And CrudOperations.Delete, I get all the columns (there's also a delete column), but userGrid.Mode = CrudOperations.Edit Or CrudOperations.Delete shows nothing.
View 1 Replies
Mar 15, 2012
I am writing an application that has to read and interpret data stored in some PDF files. The reading part is done but I am only able to get a dump of all the words on a page and not the format of the words. What I mean is that if I have to extract a table, I am getting the numbers in the table but not the markup which defines the table.Further, there is some formatting used which displays a few of these numbers within parentheses (meaning that those numbers are negative) but the parentheses themselves are not part of the text. Hence, I am not able to distinguish between positive and negative numbers present in the PDF table!
How do you get the PDF markup along with the text? Is a PDF similar in structure to an XML with tags used to markup tables etc.? If not, then, is there a resource which describes the salient features of the PDF DOM?I am using VBA and the Acrobat library (AcroExch etc.)
View 1 Replies
Apr 14, 2011
I'm trying to create a VB.Net Markup Extension per this blog post but in vb.net
<Application x:Class="Application"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
[Code]....
View 2 Replies
Apr 27, 2011
Well i have a usercontrol with a property "ClientScript" and in the aspx file where i use the usercontrol i set the value to [code]the problem here is that the is litterly passed to the property and not parsed first and replaced by the ClientID..I had the same clientscript applied to a buttons OnClientClick and there it worked...Must i apply some sort of attribute to the property to get this working? [code] i know that im saving to a local variable and that it will be cleared on reload and so on but thats not the problem here.
View 1 Replies
May 3, 2012
I want to show a MessageBox in a VB.NET application that has special markup for its text. More specifically, I want to display an unordered list. I tried doing it by wrapping the text in HTML tags (which Java Swing supports for example, if I'm not mistaken) and working with <ul> and <li>. This did how to do it without creating a completely custom messagebox class?
View 1 Replies
Jun 18, 2012
In my classic asp app, I have a markup page with a bunch of checkboxes. The checkbox control ID is bscv.Once a user checks a box and clicks submit, the value is processed on the next page called next.asp.Based on the value of the checked box, I display the correct dropdown.I use the following code on next.asp to display the correct dropdown.
If bsvc = "master" Then
' only master was checked
' "If the user checks only master checkbox, ...txtmaster with 2 options... is displayed."
%>
<select id="txtmaster" name="txtmaster">
<option value="">-Select a service-</option>
<option value="1">1</option>
[Code]...
View 2 Replies
Jul 29, 2009
I am trying to bind a RichTextBox to data from an XML file where text within a paragraph may be tagged with formatting tags. As an example the text may look like this:"The size of the area is 5000 m<superscript>2</superscript>".Text may also contain other formatting tags such as <bold> or <italic>:"The quick brown fox <bold>jumps</bold> over the <italic>lazy</italic> dog".
View 5 Replies
Apr 20, 2011
The way markup works for those that are unfamiliar is similar to html. For example, in HTML, <strong> is bold and </strong> closes the tag. In Markup, [b] is bold and [/b] closes the tag. Similar yet different.My form consists of 1 Richtextbox named RichTextBox1 and WebBrowser named WebBrowser1.In order to use HTML I use the following code:
Private Sub RichTextBox1_TextChanged(ByVal sender As Object, ByVal e As EventArgs) Handles RichTextBox1.TextChanged
WebBrowser1.DocumentText = RichTextBox1.Text
End Sub
View 2 Replies
Aug 13, 2009
I would like to create a HtmlHelper function for a specific kind of dropdown that appears on many pages in my app. I'm basically just trying to add some decoration around the existing DropDownList function, but it's being encoded.[code]....
but I'd rather make use of VB's inline XML. How do I get the results of DropDownList to not be encoded?
View 1 Replies
Sep 27, 2010
I downloaded some sample code which includes a database query within the markup code. It makes a query to the database and displays the results of the web form and I would like to divert the output to a text file and I am not sure how to do this?Can this be done from here or would it just be easier to code it in the source and make a new connection to the database?
Sample code:
<asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:ConnectionStringIP %>"
DeleteCommand="DELETE FROM [ip-to-country] WHERE [ID] = ?" InsertCommand="INSERT INTO [ip-to-country] ([ID], [BeginingIP], [EndingIP], [TwoCountryCode], [ThreeCountryCode], [CountryName]) VALUES (?, ?, ?, ?, ?, ?)"
[code]....
View 1 Replies
Jul 4, 2010
I am setting a validation rule on a series of textboxes. I'd rather not create a new instance of my custom validation rule for each TextBox.[code]
View 1 Replies
Apr 4, 2011
I've setup an ItemTeplate like so in a GridView:
<asp:TemplateField HeaderText="Building">
<ItemTemplate>
<asp:Label
[Code].....
I'm receiving the error:
EntitySet 'Building' that was specified in page markup does not exist on the Container.
There is definitely a Building entity in the pbu_housingEntities?
View 1 Replies
Sep 11, 2009
Is there a way to trigger a GridView rebind from an html markup page using jQuery or jscript?
I have an ActiveX download control which passes all events via jscript.
So, a have a download complete event on the markup page but not the code behind.
Here is the main aspx page:<asp:Content ID="Content1" ContentPlaceHolderID="Head" Runat="Server">
<script type="text/javascript" src="aurigmaiuembed.js"></script>
<script type="text/javascript">
function FileDownloader_DownloadStep(Step){
//The file list is going to be downloaded - "2 = About to Start"
if (Step == 2){
[Code]...
View 1 Replies
Jan 10, 2012
This may sound really stupid but I have to ask cause I'm not finding this answer anywhere.I have an application where the user will need to sign up for a new user account on the website [URL]..However when I am using Firefox's plug-in Firebug to view html I am getting something totally different than when I just right click on the site and view the page source.
What I am trying to do is to get the captcha from the website and display it in a picturebox on the application so the user can view the captcha, solve the captcha and then the app post is back to the service for a response.
Here is the source that I am getting using Firefox's Firebug to inspect the element:
<td>
<input type="hidden" value="Oo3Jo1I8bgzK68agMqo3s79ZZib2OkbK" name="iden">
<img class="capimage" src="/captcha/Oo3Jo1I8bgzK68agMqo3s79ZZib2OkbK.png" alt="i wonder if these things even work">
</td>
[Code]...
Why would the two be showing me two different versions of the HTML?
And how would you be able to grab that source to view in a picturebox using webclient?
View 2 Replies
Jun 20, 2009
Usage: Users create pretty HTML news letters in another app. They post the newsletter to the web, but they also want to set the contents of the HTML news letter file as the body of an email and send it using Application In Question. The users understand to use absolute link and image references when sending an E Newsletter. Environment:
AIQ is a VB.Net app deployed via ClickOnce. It is an intranet app; one can be sure MS Office 2003 and the interop 11 dlls are on the target machines.
Restrictions: MAPI is out. It mangles the HTML. Since it is a ClickOnce deployment, we can't register dlls (I think, correct me if I am wrong). Therefore CDO and COM is out (again, I may be wrong.... I would be happy to be proven so).
View 1 Replies
Aug 2, 2010
Can we use our normal vb.net applications over the net?
I mean if I try to make my windows based application, that registers students to School record using Access Database,
will it work on the internet in the same way as it does on my local computer?
View 6 Replies
Jul 20, 2010
i want to use some api's in my software . Other than api there is no other way .
I want to learn more about win32 api . Can some one tell me
And what is the difference between Native api and normal api
View 12 Replies
Sep 14, 2009
I get a number of something like 4.44444444444444E+24. How do I do to convert it to it normal form as 4444444444444444444444444. (I have to compare these to return true value if it's equal )
View 1 Replies
Jul 29, 2011
I am working on a application in which I have to show different forms stacked one upon the other. Due to some restrictions, I cannot use MDI and also it has a lot of issues. I am able to get what I want but with a problem. The forms will be stacked, but they do not remain in the parent form. Lets take it by an example. The structure goes like this.
1) There is a form A (My parent form)
2) a second form "B" opens on a button click event on Form "A". (Note: B.ShowInTaskBar=False)
3) again, a third form "C" opens on a button click event on Form "B". (Note: C.ShowInTaskBar=False)
Now, when I minimize form A, it gets minimized but the Form B and C, remains as it is. I want them to get minimized at the same time. I want form B and C should remain as a child form of form A.
View 1 Replies
Feb 2, 2010
My Form is TRANSPARENT and i dont know how to make it normal again.
View 2 Replies