|
(in visual studio 2008, website project)
I cant create instance of a partial class in a another partial class, why ????
Please look at below;
test.aspx
<%@ Page Language="VB" AutoEventWireup="false" CodeFile="test.aspx.vb" Inherits="test" %>
test.aspx.vb
Partial Class test
Inherits System.Web.UI.Page
End Class
profile.aspx
<%@ Page Language="VB" AutoEventWireup="false" CodeFile="profile.aspx.vb" Inherits="profile" %>
profile.aspx.vb
Partial Class profile
Inherits System.Web.UI.Page
' doesnt work
Dim _test as new test
End Class
i couldnt understand what is the problem ?? thanks...
thanks for everything i have...
|
|
|
|
|
Your question is a bit vague. Nothing happens? A (compile-time||run-time) error is thrown?
What were your expectations from :
TALHAKOSEN wrote: Dim _test as new test
I'm really curious.
|
|
|
|
|
i mean when i wrote
Dim _test as new ...
i cant reach my test class.
thanks for everything i have...
|
|
|
|
|
That's not an answer
Is this a website/web application??
FYI Partial classes are just a VS construct, a class is class.
|
|
|
|
|
yes, it is website application, i create it with this way in vs2008
file --> new web site
thanks for everything i have...
|
|
|
|
|
Please reread my first answer and reply to my question : What did you expect to happen? What were your intentions?
|
|
|
|
|
Estys, Thanks for your attention and sorry for my poor english ,
i couldnt explain what i wanna say excatly. Ok, i try to explain it clearly at this time,
I gave a simple sample to tell my problem before, but now i wanna give you my real project's page example.
so
I want to take a values of a textbox.text or name of a button which are in another page.
TariheGore.aspx
Imports System
Imports System.Globalization
Imports System.Threading
Imports System.Data.SqlClient
Imports System.Data
Imports System.Drawing
Imports System.Drawing.Color
Imports System.Drawing.Font
Partial Class TariheGore
Inherits System.Web.UI.Page
Public fp1 As TariheGoreDuzelt ' there are problem it says "type TariheGoreDuzelt is not defined"
Public fp2 As TariheGoreGiris ' there are problem it says "type TariheGoreGiris is not defined"
Protected WithEvents Form2 As System.Web.UI.HtmlControls.HtmlForm
Public ReadOnly Property GetBtnName() As String ' i will use this in TariheGoreGiris.aspx
Get
Return ButtonName
End Get
End Property
TariheGoreGiris.aspx
Imports System.Data.SqlClient
Imports System.Data
Imports System
Imports System.Globalization
Imports System.Threading
Partial Class TariheGoreGiris
Inherits System.Web.UI.Page
Public fpTariheGore As TariheGore
Protected WithEvents Form1 As System.Web.UI.HtmlControls.HtmlForm
Protected WithEvents CikBtn As System.Web.UI.HtmlControls.HtmlButton
Dim utl As New Utils
.
.
.
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Thread.CurrentThread.CurrentCulture = New CultureInfo("tr-TR")
if Not IsPostBack Then
Try
fpTariheGore = CType(Context.Handler, TariheGore)
BtnName = fpTariheGore.GetBtnName
i hope i could explain my problem
thanks for everything i have...
|
|
|
|
|
You are treating your website like a windows form app. Can't be done.
I think you should read up on ASP.NET.
Have you seen this : Creating ASP.NET Web Sites
In your case the lifecycle of the Page-object is something you must know by heart.
|
|
|
|
|
Thanks fot giving your time,Estys...
thanks for everything i have...
|
|
|
|
|
I was a bit hasty in saying it can't be done, always using sessionstate and querystrings.
I found this
Don't know exactly how Context behaves, but you need to do a Server.Transfer to make it function
Merry Christmas an a Happy New Year
|
|
|
|
|
Yeah i solved my problem with usin session, you are right ))
Merry Christmas an a Happy New Year to you , too
thanks for everything i have...
|
|
|
|
|
I will just ask if editable attributes for dynamic web templates is available
in expression web like the one you see in Dreamweaver. Thanks.
|
|
|
|
|
Hi
I hosted my website. I want to add a feature to that which will help me to send the sms through that website. Please help me.
|
|
|
|
|
I have implemented the same feature thought services of third party.
I am using services of Ravience [^] gateway.
They have provided there api for the Implementation process
|
|
|
|
|
i wanted that to Attract my users, i found that its not free.
Vuyiswa Maseko,
Spoted in Daniweb-- Sorry to rant. I hate websites. They are just wierd. They don't behave like normal code.
C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vuyiswamaseko.com
vuyiswa@its.co.za
http://www.itsabacus.co.za/itsabacus/
|
|
|
|
|
Why would you expect it to be? Someone has to pay eventually
Bob
Ashfield Consultants Ltd
Proud to be a 2009 Code Project MVP
|
|
|
|
|
You are Right. But i have came across a free Webservice, but it only works for India. am in South Africa so i have to buy
Vuyiswa Maseko,
Spoted in Daniweb-- Sorry to rant. I hate websites. They are just wierd. They don't behave like normal code.
C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vuyiswamaseko.com
vuyiswa@its.co.za
http://www.itsabacus.co.za/itsabacus/
|
|
|
|
|
Vuyiswa Maseko wrote: it only works for India
Did you mean http://www.smscountry.com/[^]? It is free only on a trial basis.
Vasudevan Deepak Kumar
Personal Homepage Tech Gossips
The woods are lovely, dark and deep,
But I have promises to keep,
And miles to go before I sleep,
And miles to go before I sleep!
|
|
|
|
|
Thanks i will look at it.
Vuyiswa Maseko,
Spoted in Daniweb-- Sorry to rant. I hate websites. They are just wierd. They don't behave like normal code.
C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vuyiswamaseko.com
vuyiswa@its.co.za
http://www.itsabacus.co.za/itsabacus/
|
|
|
|
|
hi,
i want to open ms word and pdf file in asp.net..
ans also need word to pdf conversion.
plz give me solution for tat..
thanks
Yours,
KaNNaN
-----------------------------------------------------------------
"Success is When Ur Signature Becomes An Autograph"
Mail To : foreverkans@gmail.com
|
|
|
|
|
|
Hi
I am working on a website in struts. For URL redirection, httpredirectfilter java interface is used in thos website. All the redirections are working fine, except one for which I sought for your help.
Currently, we have 3 locales in my site that work on 2 Top Level Domains.
Locale Names
en_US ------ For US
en_CA ------ For Canada
fr_CA ------- For Canada
Top Level Domain (TLDs)
.com
.ca
Currently all the locales work in conjunction with both the TLDs. This is affecting our GA tracking, so we decided to restrict Canada locales to .ca TLD and US locale to .com TLD. For this purpose, I made code modifications in two of the files, httpredirectfilter.xml &amp;amp;amp; .htaccess. I tested these modifications in our local environment and they work good. However, when I push them to production site, these modifications are not reflected in the live site. Not able to understand the reason for this. Hosting company says there is no configuration on their end which stops redirection. So I seek to work with you to check if this is a permission issue. In case, if its something different from permission issue, please let me now on that.
I am using following code in httpredirectfilter.xml for redirection:
<redirect match="^www.mysite.com/en_CA/(.*)$" target="http://www.mysite.ca/en_CA/$1"
permanent="yes" enitre-url="yes />
I'll be grateful for any help provided
modified on Sunday, December 20, 2009 12:48 AM
|
|
|
|
|
how to get an user account activated using memebership api in asp.net
|
|
|
|
|
I'm looking for a solution to the same.
modified on Wednesday, January 27, 2010 9:56 AM
|
|
|
|
|
Hello,
What is the best method to deploy an VS 2008 Web Application? My web application contains webservice references, libraries etc and i have to publish this to my production server which has iis 6.0 on it. Should i use VS Web Deployment method? Should i go with pre compilation and publsih the website?Or webset up project? I am confused as you can see .. Any help would be greatly appreciated.
Thanks much
|
|
|
|