Could someone please tell me a nother way I could achieve the following...
I'm having problems because of a component within mya ASP.NET page due to
the ViewState set in the component!
I currently have a text editor ("editor.aspx")
and two different content mangement pages showing the pages available to edit
viewpage.aspx
and
PgeEditor.aspx
I want to update the appropriate table in the database according to which
page the user can from eg: Chose a page from viewpage or PgeEditor
The code below works fine apart from my Boolean keeps getting reset to FALSE
in the code because of the text editor component I'm using...
Would really appritiate any suggestions... HELP
Thanks
<CODE>
' Works fine
Private Function GetDocument() As String
Dim ds As DataSet
If Request.ServerVariables("HTTP_REFERER") =
"http://localhost/cpncms_v1/cms/viewpage.aspx" Then
ds = GetDataSet(("SELECT content FROM tblPageContent WHERE
pageID=" + rowID.ToString()))
iNews = True
ElseIf Request.ServerVariables("HTTP_REFERER") =
"http://localhost/cpncms_v1/cms/news/pgeEditor.aspx" Then
ds = GetDataSet(("SELECT content FROM tblNewsArchive WHERE
newsID=" + rowID.ToString()))
iNews = False
End If
Dim table As DataTable = ds.Tables(0)
Dim row As DataRow = table.Rows(0)
Dim doc As String = row("content").ToString()
Return doc
ds.Dispose()
End Function 'GetDocument
' Sub UpdateDocument doesn't work as iNews always equals FALSE
Private Sub UpdateDocument(ByVal doc As String)
Dim strSQL As String = ""
If iNews = True Then
strSQL += "UPDATE tblPageContent SET content='"
strSQL += (doc.Replace(Chr(39), Chr(39) + Chr(39)))
strSQL += "' WHERE pageID=" + rowID.ToString()
RunQuery((strSQL))
Else
strSQL += "UPDATE tblNewsArchive SET content='"
strSQL += (doc.Replace(Chr(39), Chr(39) + Chr(39)))
strSQL += "' WHERE newsID=" + rowID.ToString()
RunQuery((strSQL))
End If
iNews = Nothing
End Sub 'UpdateDocument 4 1158
Tim::.. wrote: Could someone please tell me a nother way I could achieve the following... I'm having problems because of a component within mya ASP.NET page due to the ViewState set in the component!
I currently have a text editor ("editor.aspx")
and two different content mangement pages showing the pages available to edit
viewpage.aspx and PgeEditor.aspx
I want to update the appropriate table in the database according to which page the user can from eg: Chose a page from viewpage or PgeEditor
The code below works fine apart from my Boolean keeps getting reset to FALSE in the code because of the text editor component I'm using...
Would really appritiate any suggestions... HELP
Thanks
Why not just pass a variable to the page, in the Querystring to
differentiate the page you came from?
--
Curt Christianson
site: http://www.darkfalz.com
blog: http://blog.darkfalz.com
Thanks...
Why didn't I think of that... DOWWW!
"Curt_C [MVP]" wrote: Tim::.. wrote: Could someone please tell me a nother way I could achieve the following... I'm having problems because of a component within mya ASP.NET page due to the ViewState set in the component!
I currently have a text editor ("editor.aspx")
and two different content mangement pages showing the pages available to edit
viewpage.aspx and PgeEditor.aspx
I want to update the appropriate table in the database according to which page the user can from eg: Chose a page from viewpage or PgeEditor
The code below works fine apart from my Boolean keeps getting reset to FALSE in the code because of the text editor component I'm using...
Would really appritiate any suggestions... HELP
Thanks
Why not just pass a variable to the page, in the Querystring to differentiate the page you came from?
-- Curt Christianson site: http://www.darkfalz.com blog: http://blog.darkfalz.com
Tim::.. wrote: Could someone please tell me a nother way I could achieve the following... I'm having problems because of a component within mya ASP.NET page due to the ViewState set in the component!
I currently have a text editor ("editor.aspx")
and two different content mangement pages showing the pages available to edit
viewpage.aspx and PgeEditor.aspx
I want to update the appropriate table in the database according to which page the user can from eg: Chose a page from viewpage or PgeEditor
The code below works fine apart from my Boolean keeps getting reset to FALSE in the code because of the text editor component I'm using...
Would really appritiate any suggestions... HELP
Thanks
Why not just pass a variable to the page, in the Querystring to
differentiate the page you came from?
--
Curt Christianson
site: http://www.darkfalz.com
blog: http://blog.darkfalz.com
Thanks...
Why didn't I think of that... DOWWW!
"Curt_C [MVP]" wrote: Tim::.. wrote: Could someone please tell me a nother way I could achieve the following... I'm having problems because of a component within mya ASP.NET page due to the ViewState set in the component!
I currently have a text editor ("editor.aspx")
and two different content mangement pages showing the pages available to edit
viewpage.aspx and PgeEditor.aspx
I want to update the appropriate table in the database according to which page the user can from eg: Chose a page from viewpage or PgeEditor
The code below works fine apart from my Boolean keeps getting reset to FALSE in the code because of the text editor component I'm using...
Would really appritiate any suggestions... HELP
Thanks
Why not just pass a variable to the page, in the Querystring to differentiate the page you came from?
-- Curt Christianson site: http://www.darkfalz.com blog: http://blog.darkfalz.com This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Daniel Tan |
last post by:
Are there anyway to copy rows of records from one query to another
query and then hide the records in source query ? Pls advise. Thanks.
Regards,
Daniel
|
by: Kathy Burke |
last post by:
Hi, I'm tired, so this question may be silly. I have a fairly long sub
procedure. Based on one condition, I load another sub with the
following:
If Session("GRN") = "complete" Then
txtScan.Text...
|
by: Rabbit |
last post by:
Hi,
On my 1st page, i have a function which gets a new ID value and need to
transfer to another immediately.
which I want to get in 2nd page using Request.form("txtID"), but doesn't
work, the...
|
by: Mike |
last post by:
Hi,
I have a form with some controls, and a different class that needs to
modify some control properties at run time.
Hoy can I reference the from so I have access to its controls and...
|
by: Sin Jeong-hun |
last post by:
It seems like the Protect() uses the Windows accout information to
encrypt data. If I know the user name and the password, can I decrypt
it on another PC? If it is not, how about the exported key?...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: ryjfgjl |
last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
|
by: ryjfgjl |
last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
| |