Jump to content
Fórum Script Brasil
  • 0

(Resolvido) Mostrar Valor Da Variavel


galera no codigo abaixo estou kerendo mostrar na pagina o valor q a variavel de session está mostrando... mas keria numa variavel normal

como eu faço isso???

alguém saberia me dizer... como faz isso...???

pagina ASPX (teste.aspx)

<%@ Page Language="VB" AutoEventWireup="true" CodeFile="teste.aspx.vb" Inherits="teste.spaTeste" %>
<%@ Import namespace="teste"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<form runat="server">
<asp:Label ID="txt" runat="server"/>
script vb (teste.aspx.vb)
Imports System
Imports System.Web
Imports System.Web.UI

namespace teste
public partial class spaTeste

Inherits System.Web.UI.Page

dim aString as String

Sub Page_Load(Src As Object, E As EventArgs)
If Not IsPostBack Then
End If
End Sub

sub mostra()
dim classe as testeClass = new testeClass()
txt.Text = classe.func_retornaTxt("William")
end sub

sub titulo() 'esse function vem do meu webservice é só retirar ela para funcionar
dim aService1 as new Service1()
session("tTitulo") = aService1.spa_Titulo()
end sub

end class
end namespace

Edited by quintelab
Adicionado BBCode Code e BBCode HTML
Link to post
Share on other sites

1 answer to this question

Recommended Posts

  • 0

galera já consegui o q keria...

olha como se faz... fika ai a dica


<title runat="server"></title>
sub titulo()
dim aService1 as new Service1()
title = aService1.spa_Titulo()
end sub

deu erro quando eu coloquei "this." ai coloquei direto e funfou 100%

vlw pela ajuda...

Edited by quintelab
Adicionado BBCode Code e BBCode HTML
Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Cloud Computing

  • Forum Statistics

    • Total Topics
    • Total Posts
  • Create New...