BV Commerce Forum
»
BV Commerce Support
»
Development
»
Accessing values from input boxes within the Product.aspx page
Rank: Member
Joined: 1/30/2007(UTC) Posts: 1
|
I have a text input field defined for a product, and I'm wondering how, in the code-behind file of the product.aspx page, I can access the value that a user has typed into this field.
I first thought to create a ProductChoiceInputBase object to iterate over the LocalProduct.ChoicesAndInputs collection, and then to cast that iterator into a ProductInput object so that I can get to the DefaultValue property.
However, it appears that the DefaultValue property doesn't correspond to what a user types into the field from the web page.
Is there another approach that I should take? Am I using the correct object types/properties?
Rick.
PS: Below is a code sample that currently is not working.
For Each currentChoice As Catalog.ProductChoiceInputBase In LocalProduct.ChoicesAndInputs If currentChoice.Name = "ClientName1" Then If CType(currentChoice, Catalog.ProductInput).DefaultValue.Trim().Length < 3 Then MessageBox.ShowError("Please enter a valid name.") args.IsValid = False End If
End If Next
|
|
|
|
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.