?
Solved

Dreamweaver and Visual Studio

Posted on 2005-02-24
11
Medium Priority
?
1,298 Views
Last Modified: 2008-01-09
Hello

Is there any way I can use both visual studio .net and macromedia dreamweaver together to build asp.net web sites. I want to use the helpfull coding environment of visual studio but want to use dreamweaver for the graphics end of things. For example I want to create a page and do all my graphic editing using Dreamweaver such as adding fireworks images/buttons, flash movies etc. Then I want to code my page, for example add an onpage handler that will do something like validate user data etc. There's other great thing in dreamweaver also such as template pages etc. I want to be able to ultise all these features but do my coding in Visual studio because of the added benefits it provides such as intellisense etc.

Can this be done. Anyone point me in the right direction. It would be great to get the best of both worlds.
   
0
Comment
Question by:auk_ie
[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
  • 4
  • 3
  • 2
  • +2
11 Comments
 
LVL 16

Expert Comment

by:OliWarner
ID: 13399915
I use both. Without a problem. VS.net 2003 and MM DW MX2004.
0
 

Author Comment

by:auk_ie
ID: 13400272
Hi OliWarner

Can you explain to me how I would create a template file in dreamweaver and then use visual studio to add a C# class and create an OnPage handler.

When I try this I get all sorts of errors
0
 
LVL 16

Expert Comment

by:OliWarner
ID: 13400438
a template? like a proper dreamweaver template? you shouldnt need to use them if you've got access to including files
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 1

Expert Comment

by:Munti
ID: 13401775
DW and VS2003 works together like a charm. I use DM to do all the HTML, CSS and Javascript, and the VS2003 for the codebehind files. Don't use DW templates, can get realy messy quickly!

0
 

Expert Comment

by:headless_monkeyman
ID: 13401911
Here is my "me too", and a few quick pieces of advice that work for me.....

1) if you use source safe I suggest letting VS handle the source control. Check out the files and then work on them with dreamweaver where VS puts them. Both products will handle source safe, but confusing things can happen if you juggle.

1a) VS and source safe lack a good FTP client for deploying sites to servers. Dreamweaver on the other hand does not. I do a release build or even a partial debug build and dreamweaver can then "put" them up to the server with two clicks.

2) don't use dreamweaver's check in/check out if you can avoid it. Let VS do that stuff via source safe. Ignore anythng you can that makes extra files including notes

3) The sreamweaver "site" settings: I use the file share path of the directory I made by generating the c# project or opening it from an existing web and having it coppied over as my "Local" directory for DW. I then set the testing directory as close to or as that home directory.  I use the typical setup, so the local and test directories double up for me. Then set your destingation FTP to someplace yo'd ike to mirror the project to use that spare FTP feature :)

4)  As for your templates: right now go to google and paste in "WilsonTemplatesIntro". That and a few smart related things you will pull up should provide you with a toolbox that far exceeds what you were doing with DW templates. And these objects can render at least as placeholders in design view of both systems. Not perfect to the pixel matches all the time maybe, but darned good.

That should give you a great weekend's worth of fun.
Now I'll go back to quietly waiting for sailing season.

Kurt
0
 
LVL 2

Expert Comment

by:fromeroj
ID: 13405943
If you are open to a diferent way, i have a diferent proposition...
because i use to make web sites that way (VS + Dreamweaver )
but  i try out Visual Web Developer 2005 Express Edition Beta
http://lab.msdn.microsoft.com/express/vwd/

and feels like VS when coding and like expert's Dreamweaver when designing
 
you can downloadit while still beta for free, and eventually it will cost about 100USD, ...
try to NOT to use any C#2.0 features so you can deploy it on a .NET 1.1 IIS


0
 

Author Comment

by:auk_ie
ID: 13412049
Hi guys some very nice opinions. I want to recap on some of the points made and some of the problems I see

The procedure to create an application using these tools would be as follows
1) Create a C# website using VS Studio (for eg called MyWebsite), This will create a folder at C:/Inetpub/MyWebsite/ and also create a solution file for me at My Documents/My Projects/MyWebsite/MyWebsite.sln
2) Now the dreamweaver part, I simply create a New Site and set the local root folder to C:/Inetpub/MyWebsite/ and set the Server Model to ASP.Net.

The problem here is that in the C:/Inetpub/MyWebsite/ folder VS.net has created a whole load of files in here already such as the C# project file etc. Dreamweaver picks up on these files so thinks they are apart of the website so will upload them to the remote server if I use its ftp features. A big no no. How can I get around this?

3) So now that I have the project set up. I want to create a web page. The procedure I've tried is as follows, I create a page in dreamweaver the way I want it to look, add my forms etc.

4) Now its time to add C# code to the page. So in VS.net I add the page MyWebPage.aspx to the project and all the referenced images. Upon adding the page  VS.net kicks out the message "There is no class file in the project associated with the Web Form 'MyWebPage.aspx'.  Create a new class file now? Yes/No". So I hit yes to create a code file for the page, i.e. MyWebPage.aspx.cs. That's cool so now I can add code to this file using VS.net

This is where I get confused.
What does building the project do in VS.net?
Why would a Web Page need to be built?
What is the build the .cs built file into and how does this affect my deployment?  
What is MyWebpage.aspx.resx for?
Laslty My dreamweaver edited pages look crap in the VS.net Designer. This is not a big problem as they are rendered OK in the browser but still it woulld nice to have a resolve for this?

PS: fromeroj, why did you swap to Visual Web Developer 2005, Is this not a cut down version of VS.net, and does it have the html editing ppower of dreamweaver?

 
0
 
LVL 16

Accepted Solution

by:
OliWarner earned 1800 total points
ID: 13413777
>> A big no no. How can I get around this?
Uploading the source isnt such a bad thing. IIS is well trained in not serving source files. It will not do it unless you explicitly change the settings to pump out sourcefiles.

>> Why would a Web Page need to be built?
It doesnt, but VS.net is just trying to push code-behind techniques of having a class file and a webpage which inhertis the class and uses it like that. Technically cleaner.

>> What is the build the .cs built file into and how does this affect my deployment?
the .cs is the C# Source file for the codebehind. It IS the codebehind file.

>> What is MyWebpage.aspx.resx for?
Just a buildtime file. Shouldnt be any use for it once its out and about.

VS.net does make a lot of junk up when it comes to projects, but this is only to cover its back. There's no compiling as such in development things like this, so if you ask me, i would add VS.net to the list of editors in Dreamweaver and when you want to edit a .net page in studio, just right click the file in DW, and open in VS. That way you wont get all the junk in your build dir, but you wont get all the power of VS.

When you're making new things I have found the best way is to make it in a separate dir and move it over when its ready.

For clarification, when using codebehind techniques, you need the class.cs or class.vb and a "front" page for it like class.cs.aspx...
It could well be the other way around: source: class.aspx.cs and front: class.aspx. Both are valid.
.cs files will not be shown to users.
0
 
LVL 16

Expert Comment

by:OliWarner
ID: 13413785
Whoops missed a couple =)

>>What does building the project do in VS.net?
Nothing, just saves the source and loads IE up at the right page.

>>Why would a Web Page need to be built?
They dont. They just need to be saved.
0
 

Assisted Solution

by:headless_monkeyman
headless_monkeyman earned 200 total points
ID: 13415310
Most of your questions will answer themselves if you study up a tiny bit on how asp.net works at runtime. I reccomend that you read the first tutorials on www.asp.net or www.got.net or the help files that come with Matrix (avilable at asp.net). There are really two primary ways that .net code is compiled... and it is easy for smart folks to miss this piece of info because we tend to automaticly skip the baics in a new set of toys by skipping past the "overly easy" first few lessons.

What it comes down to is that in .net you can make single file pages that do not have procompiled logic in code behnd pages (dreamweaver's method) or you can split the logic into two tiers, content (.aspx) and behavior (.cs + .resx such as VS does).  My standard preference is to compile my logic using the code behind method, but to still keep the content editable by dreamweaver and even content management systems I develop that use Contribute (long before Macromedia started selling such an idea themselves I was making round trip content editing systems using my own code and then Contribute once it got up to the task). This makes it easier for my project teams to maintain seperate development schedules for the content and engine teams.  And precompiling makes the stuff run faster.

That said, if i were making something that was strictly  a one man site that was going to run on a single server for a small to mid sized business I'd probably do single page code and maybe not use VS at all!  

Finally, because my girlfriend reminds me that 1) i don't collect EE points (don't accept any of my answers please) and 2) its sunday which means poetrey, donuts and mourning Hunter S this week and 3) i'd better shave if i want to live I will point out to you as I say goodbye two features of DW you will want to be familiar with... First is the Cloaking feature. Takes care of your FTP issues. If you don't understand what a file is for, cloak it. This stops it from joining the FTP queue. You can cloak .cs .resx and .scc just for starters. Second is Site:Advanced:Deploy Supporting Files. This dumps out a .dll which has some of DW's featues precompiled into it which you will be needing.

Last but not least, DW's database access is a little "half baked" to be honest. So be sure and use VS for that part. Takes a little longer to learn it right, but you can always up your hourly rate to make up for it later :)

Time for my social life!

KF
0
 

Author Comment

by:auk_ie
ID: 13416022
headless_monkeyman

Had fun reading your post the most. However what do you mean hourly rate? I'm only doing this for a bit of fun. I guess thats why you have a girlfriend and I don't.

Regards Asad
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

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

This article introduced a TextBox that supports transparent background.   Introduction TextBox is the most widely used control component in GUI design. Most GUI controls do not support transparent background and more or less do not have the…
Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
Michael from AdRem Software explains how to view the most utilized and worst performing nodes in your network, by accessing the Top Charts view in NetCrunch network monitor (https://www.adremsoft.com/). Top Charts is a view in which you can set seve…
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …
Suggested Courses
Course of the Month13 days, 5 hours left to enroll

777 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