Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

VS 2003 vs 2005

Posted on 2006-10-25
10
Medium Priority
?
213 Views
Last Modified: 2012-08-13
hi there,
I have an application open in VS 2003 and by mistake someone else open it in 2005. When the conversion was done new code was added to my VB file is there a way to change back to what is supposed to be?

here is part of the code that was added to the new vb file:
Namespace CE_inquiry


Partial Class CEviolations_list
    Inherits System.Web.UI.Page

    Dim arrFileNames() As String

this lines are giving me an error that a declaration is expected
Thanks
JSCTECHY
0
Comment
Question by:jsctechy
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 4
10 Comments
 
LVL 70

Accepted Solution

by:
Éric Moreau earned 1500 total points
ID: 17803148
Hi jsctechy,

>> and by mistake someone else open it in 2005

That's why backups and/or VSS usage is important!

Replace Partial by Public.

Cheers!
0
 
LVL 1

Author Comment

by:jsctechy
ID: 17803182
yeah i know but the original code was removed long time ago and now that they want to make some changes we have an old copy of the original code.

Now when i change the partial to public i got some errors on the labels as not declared.
also i have an error on this line:
 Dim mConnectString As String = ConfigurationSettings.App9Settings("HLWD11ConnectString") 'App9Settings is not a menber of System.configuration.configurationsettings
0
 
LVL 1

Author Comment

by:jsctechy
ID: 17803230
when i try to open the ASPX file i got also an error:
This file could not be loaded into the web forms designer. Please correct the following error and then try loading it again.
Visual Studio cannot open a designer for the file because the class within it does not inherit from a class that can be visually designed.
Make sure all of the classes used in the page are built or reference in the project.
is there a way to by pass this?
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
LVL 70

Expert Comment

by:Éric Moreau
ID: 17803294
jsctechy,

You surely have a file that is having the same name as your vb file but with .designer.vb in it. Open this file in NotePad, copy its content and paste it into your main class.
0
 
LVL 1

Author Comment

by:jsctechy
ID: 17803301
in order to solve the last issue what i did i change the first line that currently have this:
<%@ Page Language="vb" AutoEventWireup="false" Inherits="CE_inquiry.CEviolations_list" CodeFile="CEviolations_list.aspx.vb" %>

by removing the inherits "" and adding the codebehing to whatever the file is.
but i can not get the labels thing to work right so i still need some help
Thanks
 
0
 
LVL 1

Author Comment

by:jsctechy
ID: 17803376
on my ASPX page i have a lblErrorDesc that will handle my errors but since i'm trying to get it to work it needs to be declare first.
here is where i'm getting my errors:
If Session("ErrorDesc") <> "" Then
                lblErrorDesc.Text = Session("ErrorDesc") & "<BR><BR>Please go back to the <A HREF=""CEviolations_query.aspx"">search screen</A> and revise your search."
                lblErrorDesc.Visible = True
            ElseIf Not Page.IsPostBack Then
                ViewState("SortOrder") = "STREET ADDRESS"
                GetViolations(ViewState("SortOrder"))
                If Session("ErrorDesc") <> "" Then
                    lblErrorDesc.Text = Session("ErrorDesc") & "<BR><BR>Please go back to the <A HREF=""CEviolations_query.aspx"">search screen</A> and revise your search."
                    lblErrorDesc.Visible = True
                End If
            End If

lblErrorDesc is not declare
0
 
LVL 70

Expert Comment

by:Éric Moreau
ID: 17803447
jsctechy,

If you don't have many controls on this page, why not just create a new page in VS.Net 2003, add your controls and then copy the code you already have?
0
 
LVL 1

Author Comment

by:jsctechy
ID: 17803490
well i have a lot of controls i just added the part where i have all the errors, thats what i'm trying to be away from re-write the whole page.
0
 
LVL 70

Expert Comment

by:Éric Moreau
ID: 17803781
jsctechy,

I am afraid that you will have to rebuild most part of it. You can try to copy as much as you can from .designer.vb file to your new form.
0
 
LVL 1

Author Comment

by:jsctechy
ID: 17806269
i was able to get a backup so we did not have to redo the whole thing
Thans for your help.
JSCTECHY
0

Featured Post

How to Use the Help Bell

Need to boost the visibility of your question for solutions? Use the Experts Exchange Help Bell to confirm priority levels and contact subject-matter experts for question attention.  Check out this how-to article for more information.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I have developed many web applications with asp & asp.net and to add and use a dropdownlist was always a very simple task, but with the new asp.net, setting the value is a bit tricky and its not similar to the old traditional method. So in this a…
In this Article, I will provide a few tips in problem and solution manner. Opening an ASPX page in Visual studio 2003 is very slow. To make it fast, please do follow below steps:   Open the Solution/Project. Right click the ASPX file to b…
Please read the paragraph below before following the instructions in the video — there are important caveats in the paragraph that I did not mention in the video. If your PaperPort 12 or PaperPort 14 is failing to start, or crashing, or hanging, …
Is your data getting by on basic protection measures? In today’s climate of debilitating malware and ransomware—like WannaCry—that may not be enough. You need to establish more than basics, like a recovery plan that protects both data and endpoints.…
Suggested Courses

618 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question